add git alias for checkout out PRs locally
This commit is contained in:
@@ -78,6 +78,10 @@
|
||||
# Kaleidoscope commands
|
||||
dkal = difftool -y -t Kaleidoscope
|
||||
remotes = remote -v
|
||||
|
||||
# check out a local copy of a PR. https://gist.github.com/gnarf/5406589
|
||||
pr = "!f() { git fetch -fu ${2:-origin} refs/pull/$1/head:pr/$1 && git checkout pr/$1; }; f"
|
||||
pr-clean = "!git for-each-ref refs/heads/pr/* --format='%(refname)' | while read ref ; do branch=${ref#refs/heads/} ; git branch -D $branch ; done"
|
||||
[color]
|
||||
diff = auto
|
||||
status = auto
|
||||
|
||||
Reference in New Issue
Block a user