-
Notifications
You must be signed in to change notification settings - Fork 0
/
.gitconfig
90 lines (82 loc) · 2.56 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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
[core]
# autocrlf = true
#whitespace = cr-at-eol
# For the vim handicapped
# editor = npp.sh
editor = vim
autocrlf = true
safecrlf = false
[diff]
tool = bc4
[merge]
tool = bc4
[mergetool "bc4"]
trustExitCode = true
[difftool]
prompt = false
[color]
branch = auto
diff = auto
status = auto
ui = auto
[color "branch"]
current = yellow reverse
local = yellow
remote = green
[color "diff"]
meta = yellow bold
frag = magenta bold
old = red bold
new = green bold
[color "status"]
added = yellow
changed = green
untracked = cyan
[user]
name = Jeff Ward
email = j.ward@techsmith.com
[credential]
helper = cache --timeout=3600
[help]
autocorrect = 1
[alias]
br = branch
c-p = cherry-pick
ci = commit
co = checkout
da = "!for name in $(git diff --ignore-submodules --name-only $1); do git difftool $1 $name & done"
das = "!for name in $(git diff --staged --ignore-submodules --name-only $1); do git difftool --staged $1 $name & done"
di = diff
dis = diff --staged
dt = difftool
mt = mergetool
permission-reset = "!git diff -p | grep -E \"^(diff|old mode|new mode)\" | sed -e \"s/^old/NEW/;s/^new/old/;s/^NEW/new/\" | git apply"
st = status --ignore-submodules
ahead = log --oneline --graph --pretty=format:'%C(magenta)%h%Creset %s %Cgreen(%cr) %C(cyan)<%an>%Creset' origin..head
aheadof = "!git log --oneline --graph --pretty=format:'%C(magenta)%h%Creset %s %Cgreen(%cr) %C(cyan)<%an>%Creset' origin/$1..head"
ahead1 = "!git ahead `git st | grep modified | cut -d':' -f2`"
blame1 = "!git blame HEAD `git st | grep modified | head -1 | cut -d':' -f2`"
behind = log --oneline head..origin
ch = cherry origin -v --abbrev=7
chmod = update-index --chmod=+x
dtree = diff-tree --no-commit-id --name-status -r
fix = commit --fixup
fix1 = "!git ahead1 | cut -d' ' -f2 | xargs git fix"
l = log --graph --pretty=format:'%C(white)%h%Creset %s %Cgreen(%cr) %C(cyan)<%an>%Creset'
mergepr = !git push origin origin/`git rev-parse --abbrev-ref HEAD`:master
rp = remote prune origin
lp = !git branch -d $(git branch --merged | grep -v main)
# Show history for commits for a line or section of a file
# git log -L 95,100:$filename
# This avoids cygwin setting everything to 755 when created
# Got the info here https://cygwin.com/ml/cygwin/2011-02/msg00121.html
# After cloning the repository run this alias on the src folder (Does other bad things)
# fixperms = setfacl -m d:u::rw-,d:g::r--,d:o:r-- .
[push]
default = nothing
[rerere]
enabled = true
[rebase]
autosquash = true
[mergetool]
keepBackup = false