-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.gitconfig
More file actions
56 lines (56 loc) · 2.08 KB
/
.gitconfig
File metadata and controls
56 lines (56 loc) · 2.08 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
[user]
name = Todd Wolfson
email = todd@twolfson.com
[mergetool]
# Do not create `.orig` files (I trust my git history competency)
keepBackup = false
[mergetool "[tool]"]
cmd = meld
[merge]
tool = meld
[color]
# Get colors for all commands
ui = true
[alias]
# Add `remote` that allows fetching of GitHub pull requests as a branch
# Interpreted from https://gist.github.com/piscisaureus/3342247
add-pr = !git config --add remote.pr.url $(git config --get remote.origin.url) && git config --add remote.pr.fetch +refs/pull/*/head:refs/remotes/origin/pr/*
add-upstream-pr = !git config --add remote.upstream-pr.url $(git config --get remote.upstream.url) && git config --add remote.upstream-pr.fetch +refs/pull/*/head:refs/remotes/upstream/pr/*
# Allow infinite `git` chains (e.g. `git git status`)
git=!git
# Get the first 7 characters of the HEAD sha
head = !git rev-parse HEAD | cut -c 1,2,3,4,5,6,7
# Quickly amend the existing commit
amend = commit --amend
# Correct typos that `help.autocorrect` does not fix
ad = add
dif = diff
# Utility methods for working with tags
tags-sorted = !git tag | (sort -V 2> /dev/null || gsort -V 2> /dev/null)
last-tag = !git tags-sorted | tail -n 1
compare-last-tag = !hub compare \"$(git last-tag)\"...master
# Clone a gist via `ssh` from an `https` url
clone-gist = "!f() { git clone $(echo \"$1\" | sed \"s/https:\\/\\/gist.github.com\\//git@gist.github.com:/\") $2; }; f"
# List sha1, author, and subject in one line
author-log = "log --format='%h %aN: %s'"
shortref = symbolic-ref --short HEAD
pus = push
[sequence]
# Edit rebases inside of Sublime Text
editor = subl -w
[help]
# Automatically correct typos within 0.7 seconds (e.g. `git sttus` -> `git status`)
autocorrect = 7
[core]
# Edit commit messages inside of `pico`
editor = pico
excludesfile = /home/todd/.gitignore
[init]
# Instantiate `git` directories with custom set of hooks
templatedir = ~/.config/victorious-git/templatedir
[push]
# Push to remote branch of the same name by default
default = current
[grep]
# Display line numbers in `git grep`
lineNumber = true