Skip to content

Instantly share code, notes, and snippets.

@jose-a-sa
Last active November 25, 2021 09:23
Show Gist options
  • Select an option

  • Save jose-a-sa/e3a44d9d012669c86fdb19c9cce8b286 to your computer and use it in GitHub Desktop.

Select an option

Save jose-a-sa/e3a44d9d012669c86fdb19c9cce8b286 to your computer and use it in GitHub Desktop.
Git Config WSL
*.nb filter=dropoutput_nb
[user]
email = [email protected]
name = Jose Sa
[alias]
lg = 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 yellow)%d%C(reset)%n'' %C(white)%s%C(reset) %C(dim white)- %an%C(reset)' --all
la = "!git config -l | grep alias | cut -c 7-"
ls = log --pretty=format:"%C(yellow)%h\\ %Cgreen%ad%Cred%d\\ %Creset%s%Cblue\\ [%cn]" --decorate --date=short
ll = log --pretty=format:"%C(yellow)%h%Cred%d\\ %Creset%s%Cblue\\ [%cn]" --decorate --numstat
dlc = diff --cached HEAD^
mnoff = merge --no-ff
mff = merge --ff
dl = "!git ll -1"
ss = status -s
st = status
cp = cherry-pick
cl = clone
ci = commit
co = checkout
br = branch
diff = diff --word-diff
dc = diff --cached
rmc = rm --cached
r = reset
r1 = reset HEAD^
r2 = reset HEAD^^
rh = reset --hard
rh1 = reset HEAD^ --hard
rh2 = reset HEAD^^ --hard
mergetest = "!f(){ git merge --no-commit --no-ff $1; git merge --abort; echo Merge"
diffr = "!f() { git diff "$1"^.."$1"; }; f"
ours = "!f() { git co --ours $@ && git add $@; }; f"
theirs = "!f() { git co --theirs $@ && git add $@; }; f"
[diff]
tool = default-difftool
[difftool "default-difftool"]
cmd = code --wait --diff $LOCAL $REMOTE
[core]
editor = code --wait
autocrlf = true
filemode = false
fildemode = false
[filter "dropoutput_nb"]
clean = mathematica-notebook-filter
smudge = cat
[credential]
helper = cache --timeout=1800
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment