-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathgitconfig
More file actions
33 lines (33 loc) · 1.24 KB
/
gitconfig
File metadata and controls
33 lines (33 loc) · 1.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
[user]
name = James Westby
email = james@jameswestby.net
[credential]
helper = cache
[core]
editor = vim
excludesfile = ~/.gitignore
pager = less -FRXS
# fsckObjects instructs git to check the object
# integrity during these operations
[receive]
fsckObjects = true
[transfer]
fsckObjects = true
[fetch]
fsckObjects = true
[push]
default = simple
[alias]
ci = commit -v
find-merge = "!sh -c 'commit=$0 && branch=${1:-HEAD} && (git rev-list $commit..$branch --ancestry-path --merges | cat -n; git rev-list $commit..$branch --first-parent | cat -n) | sort -k2 | uniq -f1 -d | sort -n | tail -1 | cut -f2'"
show-merge = "!sh -c 'merge=$(git find-merge $0 $1) && [ -n \"$merge\" ] && git show $merge'"
merged = "!sh -c 'git branch --merged ${1:-$(git main-branch)} | grep -v -e \"\\<$(git main-branch)\\>\"'"
clean-merged = "!sh -c 'git merged | grep -v \"*\" | xargs -n 1 -r git branch -d'"
clean-slate = "!sh -c 'git checkout $(git main-branch) && git pull && git clean-merged && git branch && git stash list && git status'"
ff = "!sh -c 'git merge --ff origin/$(git rev-parse --abbrev-ref HEAD)'"
main-branch = "!sh -c 'git symbolic-ref refs/remotes/origin/HEAD | cut -d/ -f4'"
[github]
user = james-w
[diff]
algorithm = patience
noprefix = true