-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.gitconfig
50 lines (45 loc) · 1.68 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
[user]
name = Anders L. Hurum
email = andershurum@gmail.com
signinkey = <key>
signingkey = <key>
[alias]
s = status
c = commit -e
ch = checkout
aa = add --all
ap = add --patch
d = diff
ds = diff --staged
l = log
lg = log --graph --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) - %C(bold cyan)%aD%C(reset) %C(bold green)(%ar)%C(reset)%C(bold yellow)%d%C(reset)%n'' %C(white)%s%C(reset) %C(dim white)- %an%C(reset)' --all
rb = rebase
rbs = rebase --skip
rbc = rebase --continue
rba = rebase --abort
st = stash
stpa = stash push -a
stpam = stash push -a -m
stpop = stash pop
stap = stash apply
pl = pull
initignore = !read -p 'Ignore languages (seperate w/ "," no spaces): ' langignore && \
wget -O .gitignore "https://www.gitignore.io/api/${langignore}" && \
git add .gitignore && \
git commit -m\"[AUTO] Added gitignore - ignoring for lang :: [${langignore}]\"
prefixbranch = !export PREFIX=${1?Missing first argument for prefix} && \
export BRANCH_RENAME=$(git branch | fzf | awk '{print $NF}') && \
export NEW_BRANCH_NAME=$PREFIX/$BRANCH_RENAME && \
echo "Running with prefix : $PREFIX" && \
echo "Renaming branch : $BRANCH_RENAME to $NEW_BRANCH_NAME" && \
git branch -m $BRANCH_RENAME $NEW_BRANCH_NAME && \
echo -e "Successfully renamed branch $NEW_BRANCH_NAME, pushing upstream" && \
git push origin :$BRANCH_RENAME && \
git push -u origin $NEW_BRANCH_NAME && \
echo "New branch name : $NEW_BRANCH_NAME"
[commit]
gpgsign = true
[gpg]
program = gpg2
[push]
default = current