-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy path.gitconfig
75 lines (60 loc) · 1.57 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
# -------------------------------
# 1. USER
# -------------------------------
[user]
name = INSERT NAME HERE
email = INSERT EMAIL HERE
# -------------------------------
# 2. ALIAS
# -------------------------------
[alias]
# status
s = status
# adding files
a = add
# committing
c = commit -m
xa = commit -a -m
amend = commit --amend -m
# branches
f = fetch
br = branch
co = checkout
master = checkout master
# Switch to a branch, creating it if necessary
go = checkout -B
# pushing and pulling
pu = push origin
pl = pull --rebase origin
# will put a file into gitignore
ignore=!([ ! -e .gitignore ] && touch .gitignore) | echo $1 >>.gitignore
# misc
hist = log --pretty=format:'%h %ad | %s%d [%an]' --graph --date=short
# For when you fuck up
remove-last = reset --soft HEAD~1
remove-last-hard = reset --hard HEAD~1
# Will start a repo in the current directory
this = !git init && git add . && git commit -m \"initial commit\"
# list aliases
alias = config --get-regexp alias
# -------------------------------
# 3. COLOR
# -------------------------------
[color]
ui = true
[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
[merge]
# Include summaries of merged commits in newly created merge commit messages
log = true