Skip to content

Instantly share code, notes, and snippets.

@theimowski
Created January 23, 2017 11:34
Show Gist options
  • Save theimowski/eaefe3d5eb4991aede82a0303d46d852 to your computer and use it in GitHub Desktop.
Save theimowski/eaefe3d5eb4991aede82a0303d46d852 to your computer and use it in GitHub Desktop.
Git config for windows box
[alias]
co = checkout
ci = commit
br = branch
st = status
l = log --graph --pretty=format:'%Cred%h%Creset%C(yellow)%d%Creset %s %C(cyan)<%an>%Creset' --all
lg = log --graph --all --decorate --abbrev-commit
lgo = log --graph --oneline --all --decorate
compare = "!f(){ git diff ${1}... --name-status; };f"
comparet = "!f(){ git difftool ${1}...; };f"
gofwd = "!f(){ git checkout `git rev-list --topo-order HEAD..${1} | tail -1`; };f"
sync = !"git fetch origin -v; git fetch upstream -v; git remote prune origin; git remote prune upstream; git rebase upstream/master"
reset-cl = !"git reset --hard; git clean -fxd"
rmgh = branch -d -r upstream/gh-pages
[color]
ui = auto
[color "branch"]
current = green bold
local = green
[color "decorate"]
HEAD = cyan reverse
[core]
autocrlf = true
editor = vim
[help]
autocorrect = 1
[log]
date = relative
[push]
default = simple
[user]
name = Tomasz Heimowski
email = tomek.heimowski@gmail.com
[diff]
tool = p4merge
renameLimit = 800
[difftool]
prompt = true
[fetch]
prune = true
[merge]
tool = p4merge
[mergetool]
prompt = false
keepBackup = false
[difftool "semanticdiff"]
cmd = $APPDATA/../Local/PlasticSCM4/semanticmerge/semanticmergetool.exe -s \"$LOCAL\" -d \"$REMOTE\"
[mergetool "semanticmerge"]
cmd = $APPDATA/../Local/PlasticSCM4/semanticmerge/semanticmergetool.exe -d \"$LOCAL\" -s \"$REMOTE\" -b \"$BASE\" -r \"$MERGED\"
trustExitCode = true
[mergetool "p4merge"]
path = C:\\Program Files\\Perforce\\p4merge.exe
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment