-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.gitconfig
45 lines (40 loc) · 1.99 KB
/
.gitconfig
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
[user]
name = Matti Kortelainen
email = [email protected]
github = makortel
[core]
pager = less -FRSXi
sparsecheckout = true
excludesfile = ~/dotfiles/.gitignore
[alias]
# tree = log --graph --pretty=oneline --abbrev-commit --decorate
# https://coderwall.com/p/euwpig
lg = log --pretty=format:'%C(bold red)%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --no-merges
lgmerges = log --pretty=format:'%C(bold red)%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --merges
tree = log --graph --decorate --pretty=format:'%C(bold red)%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset'
ffmerge = merge --ff-only
# http://blogs.atlassian.com/2014/10/advanced-git-aliases/
cms-diff-pkg = "!f() { git diff --name-only $@ | cut -d/ -f-2 | uniq; }; f"
cms-remote-add = "!f() { git remote add $1 https://github.com/$1/cmssw.git; }; f"
amend-author-date = "!f() { git commit --amend --no-edit --date \"$(git show -s --format=%ai $1)\"; }; f"
listrefs = for-each-ref --sort=committerdate --format='%(HEAD) %(color:yellow)%(refname:short)%(color:reset) - %(color:red)%(objectname:short)%(color:reset) - %(contents:subject) - %(authorname) (%(color:green)%(committerdate:relative)%(color:reset))' # refs/heads or refs/remotes(/makortel)
[color]
ui = auto
# Theme originally from from http://nathanhoad.net/how-to-colours-in-git
[color "branch"]
current = green bold
remote = yellow
[color "diff"]
meta = yellow bold
frag = magenta
old = red bold
new = green bold
[color "status"]
added = green bold
changed = yellow bold
untracked = cyan bold
# http://stackoverflow.com/questions/15321472/how-could-i-force-mergetool-gui-kdiff3-to-be-always-shown
[mergetool "kdiff3NoAuto"]
cmd = kdiff3 --L1 \"$MERGED (Base)\" --L2 \"$MERGED (Local)\" --L3 \"$MERGED (Remote)\" -o \"$MERGED\" \"$BASE\" \"$LOCAL\" \"$REMOTE\"
[push]
default = simple