Giter Club home page Giter Club logo

git-profiled's Introduction

git-profiled

git-profiled is a powerful, user-friendly Command Line Interface (CLI) tool designed for developers who manage multiple Git profiles. It acts as a transparent Git proxy, enforcing local identity configuration for each repository, ensuring you always commit and add with the correct identity. Unconfigured repositories will be unable to commit or add until a profile is selected.

This tool seamlessly integrates with your Git workflow, simply forwarding your command-line instructions to the real Git.

Features & Screenshots

Image Description


  • Enforces local identity configuration, eliminating mistaken commits with the wrong identity.
  • Automatic profile selection based on the current repository.
  • Intuitive command-line interface for managing and switching between different Git profiles.
  • Cross-platform support: macOS, Linux, and Windows.

Installation

macOS (Homebrew)

brew update
brew tap saga420/git-profiled https://github.com/saga420/git-profiled
brew install git-profiled

Linux / Windows

Pre-compiled binaries are available to download from the Releases page.

Usage

Before using git-profiled, you need to create a .git_profiled_config file in your home directory. This file should be in TOML format, and contains one or more profiles with their respective names and email addresses:

[profile1]
name = "Your Name"
email = "[email protected]"

[profile2]
name = "Your Other Name"
email = "[email protected]"

Once the configuration file is set up, you can use git-profiled in place of your usual git command. It will prompt you to choose a profile the first time you make a commit in a new repository.

Setting Up Alias

To make git-profiled the default git command, you can set up an alias in your shell configuration file (.bashrc, .zshrc, etc.). Here is an example for a bash shell:

echo "alias git='git-profiled'" >> ~/.bashrc
source ~/.bashrc

For Zsh users, replace .bashrc with .zshrc.

git-profiled's People

Contributors

saga420 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.