summaryrefslogtreecommitdiff
path: root/git_alias
blob: 2ed2eaff6d04d2f94eb390ae66cb9d479817e3da (plain)
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
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
#!/bin/bash
alias gb='git branch'
alias gba='gb -a'
alias gco='git checkout'
alias gcob='gco -b'

alias ga='git add'
alias gd='git diff'
alias gdc='git diff --cached'
alias gc='git cherry-pick'
alias gl='git log '
alias glo='gl --oneline'
alias glome='glo --author=viresh'
alias glor='glo --reverse'
alias gloo='gl --pretty=onelin'
alias glf='gl --pretty=fixes'
glfs() { glf $1 | head -1; }
alias gls='gl --stat'
alias glsp='gls -p'
alias glspr='glsp --reverse'
alias glspme='glsp --author=viresh'
alias gs='git status'
alias gsh='git show --stat -p'
alias gca='git commit --amend'
alias gcf='git commit --fixup'
alias gcs='git commit -s'
alias gcsm='git commit -s -m'
alias tgca='GIT_EDITOR=cat gca'
alias tgrevert='GIT_EDITOR=cat git revert -s'
alias gcah='gca -C HEAD'
alias gcara='gcah --reset-author'
alias gcdc='git commit --date="`date`" -c '
alias gampcp='mv /media/psf/Home/Documents/[1-9].txt ~/Downloads/patches/'
alias gamp='git am -3 ~/Downloads/patches/*'
alias cgamp='dos2unix ~/Downloads/patches/*'
alias dgamp='rm -rf ~/Downloads/patches/*'
alias mgamp='git am -3 ~/scripts/mutt/incoming/*.mbox'

alias gr='git rebase -i'
alias tgr='GIT_EDITOR=cat gr'
alias gra='gr --autosquash'
alias tgra='GIT_EDITOR=cat gra'
alias gro='gr origin/master'
alias grao='gra origin/master'
alias graa='gra ara-google/ara/main'
alias graan='gra ara-google/ara/main-next'
#alias graan='gra ara-google-noreview/ara/main'
alias grh='git reset --hard '
alias grhm='git reset --hard origin/master'
alias grs='git rebase --skip'
alias grc='git rebase --continue'
alias tgrc='GIT_EDITOR=cat grc'

alias grv='git remote -v'

alias gf='git fetch -p'
alias gfo='gf -p origin'
alias gfa='gf -p ara-google'
alias gfan='gf -p ara-google-noreview'
alias gfs='gf -p self'
alias gp='git push -f'
alias gp='git push -f'
alias gpa='git push --mirror'
alias gerritpush='git push ara-google HEAD:refs/for/ara/main'
gerritpushf() { git push -f ara-google HEAD:refs/for/ara/main/$1; }
gerritpushs() { git push -f ara-google HEAD:refs/heads/sandbox/vireshk/$1; }
alias gpo='gp origin '
alias gpl='gp linaro '
alias gps='git push self --mirror'

alias ggrep='git grep'
alias gk='gitk --all -100&'

alias cpatch='scripts/checkpatch.pl --strict'
alias cpatcha='cpatch *.patch'
alias gpatch='git format-patch -C -M --thread=shallow'
alias gpatchc='gpatch --cover-letter'
gpatchcs() { gpatchc --subject-prefix="PATCH V$1" $2; }
alias ph='gpatch HEAD^'
phc() { gpatch $1^..$1; }
rpull() { git request-pull remotes/linux-linaro/linux-linaro-core-tracking git://git.linaro.org/arm/big.LITTLE/mp.git $1 > ../pull.txt; gvim ../pull.txt; }
cpufreqrpull() { git request-pull origin/master git://git.linaro.org/people/vireshk/linux.git $1 > ../pull.txt; gvim ../pull.txt; }

alias gitgetcclist='for i in `cat ../test`; do gls HEAD~200.. -- $i > ../pull.txt;echo $i; cat ../pull.txt | grep -e Acked -e Cc | sort -u; echo ""; done | less'

alias mmcmail='git send-email --to=linux-mmc@vger.kernel.org'
alias armmail='git send-email --to=linux-arm-kernel@lists.infradead.org '
#rmk patch tracker mail
alias armpatchmail='git send-email --to=patches@arm.linux.org.uk'

alias linarorebase='/home/vireshk/scripts/linarorebase.sh rebase'
alias linaroclrrebase='/home/vireshk/scripts/linarorebase.sh clear_rebase'
alias linaropush='/home/vireshk/scripts/linarorebase.sh push'
alias linarostat='/home/vireshk/scripts/linarorebase.sh stat'
alias linarocheck='/home/vireshk/scripts/linarorebase.sh check'
#alias mypatchcountrank='gl --no-merges --format="%aN" v3.12..lnext/master | sort | uniq -ic| sort -nr | less'
#alias mypatchcount='glo  --author=viresh --no-merges origin/master | wc -l'
mypatch() { glo  --author=viresh --no-merges $1 ; }
mypatchcount() { glo  --author=viresh --no-merges $1 | wc -l; }
mypatchcountrank() { gl --no-merges --format="%aN" $1..$2 | sort | uniq -ic| sort -nr | less; }

#Other tools
alias myspatch='echo "spatch -in_place -include_headers -sp_file setmode.cocci -dir drivers/"'

# Gitmail
alias gitmail='git send-email *.patch --cc vireshk'
alias gitmailsuppress='git -c sendemail.tocmd=true send-email *.patch --suppress-cc=all --cc vireshk'
alias gitmaillinaro='gitmail --cc linaro'
alias gitmailpm='gitmail --to rafael --cc pm --cc vingu'
alias gitmailopp='gitmail --to rafael --cc pm --cc sboyd --cc "Nishanth Menon <nm@ti.com>"'
alias gitmailsched='gitmail --cc lkml --to ingo --to peterz --cc vingu'
alias gitmailschedutil='gitmailpm --to ingo --to peterz --cc vingu'
alias gitmailtimer='gitmail --cc lkml --to tglx --cc fw --cc vingu'
alias gitmailgenpd='gitmailopp --to ulf.hansson@linaro.org --to "Kevin Hilman <khilman@kernel.org>" --cc "robh+dt@kernel.org" --cc lina.iyer@linaro.org --cc rnayak@codeaurora.org --cc sudeep.holla@arm.com'
alias gitmailgenpdsuppress='gitmailsuppress --to rafael --cc pm --cc vingu --cc sboyd --cc "Nishanth Menon <nm@ti.com>" --to ulf.hansson@linaro.org --to "Kevin Hilman <khilman@kernel.org>" --cc "robh+dt@kernel.org" --cc lina.iyer@linaro.org --cc rnayak@codeaurora.org --cc sudeep.holla@arm.com --cc lkml --cc "Len Brown <len.brown@intel.com>" --cc "Pavel Machek <pavel@ucw.cz>" --cc "Andy Gross <andy.gross@linaro.org>" --cc "David Brown <david.brown@linaro.org>"'
alias gitmailbootconstraint='gitmail  --cc vingu --to greg --cc broonie --cc sboyd --cc rnayak --cc "Shiraz Hashim <shashim@codeaurora.org>" --cc lkml --cc lakml --cc robdclark@gmail.com'


# fetch remotes
alias gitsyncpmko='ssh git@gitolite.kernel.org track fetch pub/scm/linux/kernel/git/vireshk/pm.git next;ssh git@gitolite.kernel.org track fetch pub/scm/linux/kernel/git/vireshk/pm.git linus;'
alias gitsynclko='ssh git@gitolite.kernel.org track fetch pub/scm/linux/kernel/git/vireshk/linux.git next;ssh git@gitolite.kernel.org track fetch pub/scm/linux/kernel/git/vireshk/linux.git linus;'
alias gitsyncpmlo='ssh git@git.linaro.org track fetch people/viresh.kumar/linux.git lnext;ssh git@git.linaro.org track fetch people/viresh.kumar/linux.git linus;'
alias gitsyncllo='ssh git@git.linaro.org track fetch people/viresh.kumar/mylinux.git lnext;ssh git@git.linaro.org track fetch people/viresh.kumar/mylinux.git linus;'
alias gitsyncko="cd /home/vireshk/work/repos/devel/linux/; gitsyncpmko gitsynclko"
alias gitsynclo="cd /home/vireshk/work/repos/devel/linux/; gitsyncpmlo gitsyncllo"