-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy path.gitconfig
More file actions
70 lines (61 loc) · 2.24 KB
/
.gitconfig
File metadata and controls
70 lines (61 loc) · 2.24 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
[user]
user = Salem Hilal
email = hi@salem.io
name = salemhilal
[core]
autocrlf = false
# Globally ignore things in the gitignore file
excludesfile = ~/.gitignore
# Use highlighting and diff-so-fancy as the pager.
pager = less --tabs=4 -+F -+X -c
whitespace = fix,-indent-with-non-tab,trailing-space,cr-at-eol
editor = vim
[advice]
statusHints = false
[alias]
# Terse aliases
st = status
unadd = reset HEAD
br = branch
d = diff
dc = diff --cached
# I didn't alias "commit" because you should mean that shit.
# Pull, using rebase
rpull = pull --rebase --stat
pullr = pull --rebase --stat
# Get rid of whatever you were working on
fuckit = checkout .
# Diff, but minus stuff I don't care about
doff = diff --ignore-space-at-eol -b -w --ignore-blank-lines
# What did I do between yesterday and right now?
standup = "!git log --author $USER --since 'yesterday midnight' --oneline"
# Keep rpulling until you can push
superpush = "!until git rpull && git push; do : ; done"
# clean things up when git feels slow
lol-come-on-man = "!git gc && git prune && git remote prune origin"
# Fix that thing when you accidentally type `git git status`
git = !exec git
# If the remote version of a branch is gone, delete the local version too
delete-local-orphans = "!git remote prune origin && git branch -vv | grep 'origin/.*: gone]' | awk '{print $1}' | xargs git branch -d"
# Git log, but with styling
logg = log --graph --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) - %C(bold green)(%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(bold yellow)%d%C(reset)' --all
[credential]
helper = cache --timeout=86400
[color]
ui = true
meta = yellow bold
frag = magenta bold
old = red bold
new = green bold
[color "diff"]
whitespace = red reverse
[color "status"]
added = green
changed = yellow
untracked = cyan
[github]
username = shilal
; token = YOUR_GITHUB_OAUTH_TOKEN_HERE
; gist-oauth-token = YOUR_GIST_OAUTH_TOKEN_HERE
[init]
defaultBranch = main