-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.gitconfig
More file actions
77 lines (77 loc) · 2.1 KB
/
Copy path.gitconfig
File metadata and controls
77 lines (77 loc) · 2.1 KB
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
[user]
name = Laura Schanno
email = lbschanno@gmail.com
[color]
# Enable colors in color-supporting terminals.
ui = auto
[color "branch"]
current = yellow reverse
local = yellow
remote = green
upstream = cyan
[color "diff"]
meta = yellow bold
frag = magenta bold
old = red bold
new = green bold
[color "status"]
added = yellow
changed = green
untracked = cyan
[alias]
#List available aliases.
aliases = !git config --get-regexp alias | sed -re 's/alias\\.(\\S*)\\s(.*)$/\\1 = \\2/g'
# Command shortcuts
c = commit
cm = commit -m
co = checkout
coall = checkout -- .
cob = checkout -b
s = status
b = branch
a = add
aa = add -A
amend = commit --amend
f = fetch -p
# Display oneline log.
ls = log --date=relative --oneline
# Display tree-like log.
lg = log --graph --date=relative --pretty=tformat:'%Cred%h%Creset -%C(auto)%d%Creset %s %Cgreen(%an %ad)%Creset'
# Update last commit with staged files without editing message.
oops = commit --amend --no-edit
# Edit the last commit message.
reword = commit --amend
# Undo last commit but keep changed files in stage.
uncommit = reset --soft HEAD~1
# Remove file(s) from Git but not from disk.
untrack = rm --cache --
# List local commits that weren't pushed yet.
review-local = "!git lg @{push}"
# Use fzf to support selecting files to add from commandline.
ffa = "!git ls-files -m -o --exclude-standard | fzf --print0 -m | xargs -0 -t -o git add"
[core]
autocrlf = input
editor = vim
[diff]
# Use better, descriptive initials (c, i, w) instead of a/b.
mnemonicPrefix = true
# Show renames/moves as such.
renames = true
# Set the diff tool.
tool = meld
[difftool]
prompt = false
[difftool "meld"]
cmd = meld "$LOCAL" "$REMOTE"
[log]
# Use abbreviated SHAs whenever possible instead of full 40 chars.
abbrevCommit = true
[push]
# Always push to upstream.
default = current
[pull]
# Rebase when pulling.
rebase = true
[tag]
# Sort tags.
sort = version:refname