Last active
April 12, 2022 14:25
-
-
Save debuti/6b94800c8a4efe42fa25844ccc963ab4 to your computer and use it in GitHub Desktop.
.gitconfig and .bashrc
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
color_prompt="yes" | |
parse_git_branch() { | |
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/(\1)/' | |
} | |
if [ "$color_prompt" = "yes" ]; then | |
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[01;31m\]$(parse_git_branch)\[\033[00m\]\$ ' | |
else | |
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w$(parse_git_branch)\$ ' | |
fi | |
unset color_prompt | |
alias l="ls" | |
alias ll="ls -la" | |
alias fheref="find -L . -type f" |
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
[http] | |
sslVerify = false | |
[user] | |
email = <fill-in-email> | |
name = <fill-in-name> | |
[credential] | |
helper = store | |
[push] | |
default = simple | |
[diff] | |
tool = meld | |
[difftool] | |
prompt = false | |
[difftool "meld"] | |
cmd = meld "$LOCAL" "$REMOTE" | |
[merge] | |
tool = meld | |
[mergetool "meld"] | |
cmd = meld "$LOCAL" "$BASE" "$REMOTE" --output "$MERGED" | |
[alias] | |
ci = !"git commit" | |
co = !"git checkout" | |
st = "status" | |
lg = !"git lg1 --date-order" | |
lg1 = !"git lg1-specific --all" | |
lg2 = !"git lg2-specific --all" | |
lg3 = !"git lg3-specific --all" | |
lg1-specific = log --graph --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) - %C(bold green)(%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(auto)%d%C(reset)' | |
lg2-specific = log --graph --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) - %C(bold cyan)%aD%C(reset) %C(bold green)(%ar)%C(reset)%C(auto)%d%C(reset)%n'' %C(white)%s%C(reset) %C(dim white)- %an%C(reset)' | |
lg3-specific = log --graph --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) - %C(bold cyan)%aD%C(reset) %C(bold green)(%ar)%C(reset) %C(bold cyan)(committed: %cD)%C(reset) %C(auto)%d%C(reset)%n'' %C(white)%s%C(reset)%n'' %C(dim white)- %an <%ae> %C(reset) %C(dim white)(committer: %cn <%ce>)%C(reset)' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment