forked from Hubbitus/configs
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.gitconfig
113 lines (96 loc) · 2.94 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
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
[user]
name = Pavel Alexeev
email = [email protected]
# Colors from http://jblevins.org/log/git-colors
[color]
ui = auto
branch = auto
diff = auto
status = auto
[color "branch"]
current = yellow reverse
local = yellow
remote = green
[color "diff"]
meta = yellow bold
frag = magenta bold
old = red bold
new = green bold
whitespace = red reverse
[color "status"]
added = yellow
changed = green
untracked = cyan
[core]
editor = mcedit
quotepath = false
compression = 9
autocrlf = input
[merge]
tool = meld
# Workaround of BUG https://bugzilla.redhat.com/show_bug.cgi?id=1216120#c3
[mergetool "meld"]
hasOutput = true
[push]
#? default = simple
default = tracking
# http://alblue.bandlem.com/2011/04/git-tip-of-week-aliases.html
[alias]
a = add
b = branch
c = commit
# "commit and push". http://stackoverflow.com/questions/19595067/git-add-commit-and-push-commands-in-one
cp = "!f() { git add -A && git commit -m \"$@\" && git push; }; f"
ch = checkout
# http://stackoverflow.com/questions/5257553/coloring-white-space-in-git-diffs-output/5259137#5259137
d = diff --ws-error-highlight=all
# Meld for now (http://stackoverflow.com/questions/2006032/view-differences-of-branches-with-meld). See also meld alias
d-t = difftool
d-ignore-space-at-eol = diff --ignore-space-at-eol
d-ignore-spaces = diff --ignore-blank-lines --ignore-space-change
# http://stackoverflow.com/questions/3920650/git-diff-show-me-line-ending-changes/36604948#36604948
d-w = diff --word-diff-regex=.
d-word = diff --word-diff-regex=.
f = fetch
meld = difftool
ph = push
pl = pull
ps = push
r = remote -v
s = status
st = status
# http://stackoverflow.com/questions/11269256/how-to-name-and-retrieve-a-stash-by-name-in-git
# ssave "some meaningfull name"
ssave = stash save
sshow = "!f() { git stash show stash^{/$*}; }; f"
sshowdiff = "!f() { git stash show -p stash^{/$*} -p; }; f"
sapply = "!f() { git stash apply stash^{/$*}; }; f"
# Define 'git last' to show last commit message
last = show -s HEAD^{commit}
# http://alblue.bandlem.com/2011/05/git-tip-of-week-reflogs.html
undo = reset HEAD@{1}
# http://stackoverflow.com/a/24396192/307525
ignore = update-index --assume-unchanged
unignore = update-index --no-assume-unchanged
ignored = !git ls-files -v | grep ^[[:lower:]]
# http://githowto.com/ru/aliases
hist = log --pretty=format:\"%h %ad | %s%d [%an]\" --graph --date=short
type = cat-file -t
dump = cat-file -p
# http://stackoverflow.com/questions/1064361/unable-to-show-a-git-tree-in-terminal
tree = log --graph --oneline --all
# http://stackoverflow.com/questions/1527234/finding-a-branch-point-with-git
branchdiff = !sh -c \"git diff `git oldest-ancestor`..\"
branchlog = !sh -c \"git log `git oldest-ancestor`..\"
[branch]
# https://www.atlassian.com/git/tutorial/remote-repositories#!pull
#? autosetuprebase = always
[rerere]
enabled = true
autoupdate = true
[pull]
rebase = false
[difftool]
prompt = false
[diff]
wsErrorHighlight = all