Save git profiles and easily switch between them.
-
Download
gitswitcher
executable from the latest release -
Place it somewhere of your choosing on your system
-
Rename the file to
gitswitcher
(or anything that might suit you better) -
Set its permissions
chmod +x /path/to/gitswitcher
-
Add the executable parent directory to your $PATH
# fish -> ~/.config/fish/config.fish set --export PATH /path/to/gitswitcher/parent/directory $PATH # If you placed your executable file at ~/Documents/bin/gitswitcher, you can add it to your $PATH like this: # set --export PATH ~/Documents/bin $PATH # bash -> ~/.bashrc export PATH=/path/to/gitswitcher/parent/directory:$PATH # If you placed your executable file at ~/Documents/bin/gitswitcher, you can add it to your $PATH like this: # export PATH=~/Documents/bin:$PATH # zsh -> ~/.zshrc export PATH=/path/to/gitswitcher/parent/directory:$PATH # If you placed your executable file at ~/Documents/bin/gitswitcher, you can add it to your $PATH like this: # export PATH=~/Documents/bin:$PATH
-
Restart your shell
-
Stat using the commands!
gitswitcher add # to add a new profile
gitswitcher use # to use an existing profile
gitswitcher edit # to edit an existing profile
gitswitcher rm # to delete an existing profile
gitswitcher list # to list the current gitswitcher config file that contains the profiles