Last active
June 7, 2024 14:19
-
-
Save peternied/3eb59709045888a95cbb to your computer and use it in GitHub Desktop.
GIT LOL
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### SSL Setup | |
ssh-keygen -t ed25519 -C "petern@amazon.com" | |
eval "$(ssh-agent -s)" | |
ssh-add ~/.ssh/id_ed25519 | |
cat ~/.ssh/id_ed25519.pub # Paste me into a new SSH key on https://github.com/settings/keys | |
### Running ZSH? | |
echo $SHELL | |
### ZSH Git Command Prompt https://salferrarello.com/zsh-git-status-prompt/ | |
wget https://github.com/olivierverdier/zsh-git-prompt/archive/refs/heads/master.zip | |
unzip master.zip ~/.zsh-git-prompt | |
rm master.zip | |
echo "source ~/.zsh-git-prompt/zsh-git-prompt-master/zshrc.sh" >> .zshrc | |
echo "PROMPT='%~%b $(git_super_status)' >> .zshrc | |
echo "%# '' >> .zshrc | |
echo 'ZSH_THEME_GIT_PROMPT_PREFIX=""' >> .zshrc | |
echo 'ZSH_THEME_GIT_PROMPT_SUFFIX=""' >> .zshrc | |
echo 'ZSH_THEME_GIT_PROMPT_SEPARATOR=" | "' >> .zshrc | |
echo 'ZSH_THEME_GIT_PROMPT_BRANCH="%{$fg_bold[cyan]%}" >> .zshrc | |
echo 'ZSH_THEME_GIT_PROMPT_STAGED="%{$fg[yellow]%}%{●%G%}" >> .zshrc | |
echo 'ZSH_THEME_GIT_PROMPT_CONFLICTS="%{$fg[red]%}%{✖%G%}" >> .zshrc | |
echo 'ZSH_THEME_GIT_PROMPT_CHANGED="%{$fg[white]%}%{✚%G%}" >> .zshrc | |
### GIT Configuration | |
git config --global --add color.ui true | |
git config --global --add alias.lol "log --graph --decorate --pretty=oneline --abbrev-commit --all" | |
git config --global --add alias.lolb "log --graph --decorate --pretty=oneline --abbrev-commit" | |
git config --global --add rebase.instructionFormat "(%an <%ae>) %s" | |
git config --global --add checkout.defaultRemote origin |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment