Skip to content

Instantly share code, notes, and snippets.

@anson-vandoren
Last active May 19, 2020 18:02
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anson-vandoren/f93618d8b17856776820ac6e3f0c0ddd to your computer and use it in GitHub Desktop.
Save anson-vandoren/f93618d8b17856776820ac6e3f0c0ddd to your computer and use it in GitHub Desktop.
Basic .gitconfig for Windows
[user]
name = John Q. Developer
email = johnqdev@company.com
[alias]
l = log --pretty=oneline -n 20 --graph --abbrev-commit
go = "!f() { git checkout -b \"$1\" 2> /dev/null || git checkout \"$1\"; }; f"
branches = branch -a
remotes = remote -v
amend = commit --amend --reuse-message=HEAD
parent = "!git show-branch | grep '*' | grep -v \"$(git rev-parse --abbrev-ref HEAD)\" | head -n1 | sed 's/.*\\[\\(.*\\)\\].*/\\1/'"
[color]
ui = true
[color "branch"]
current = yellow reverse
local = yellow
remote = green
[color "diff"]
meta = yellow
frag = magenta bold
old = red bold
new = green bold
commit = yellow bold
whitespace = red reverse
[color "status"]
added = yellow
changed = green
untracked = cyan
[diff]
tool = bc4
[difftool "bc4"]
cmd = \"C:\\Program Files\\Beyond Compare 4\\BComp.exe\" \"$LOCAL\" \"$REMOTE\"
[merge]
tool = bc4
[mergetool "bc4"]
cmd = \"C:\\Program Files\\Beyond Compare 4\\BComp.exe\" \"$LOCAL\" \"$REMOTE\"
[filter "lfs"]
clean = git-lfs clean -- %f
smudge = git-lfs smudge -- %f
process = git-lfs filter-process
required = true
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment