commit 232397fa404b5452c39275cebca2b5c4c5359c3f parent 04978adf456a8e57b1f401d7b6439d9e018621e9 Author: William Casarin <jb55@jb55.com> Date: Sat, 19 Sep 2020 05:03:37 -0700 bin/github-refs: customize upstream Diffstat:
M | bin/git-github-refs | | | 6 | ++++-- |
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/bin/git-github-refs b/bin/git-github-refs @@ -2,7 +2,9 @@ set -e -git config --add remote.origin.fetch '+refs/pull/*/head:refs/pull/origin/*' -git config --add remote.origin.fetch '+refs/pull/*/merge:refs/merge/origin/*' +upstream=${1:-origin} + +git config --add "remote.$upstream.fetch" "+refs/pull/*/head:refs/pull/$upstream/*" +git config --add "remote.$upstream.fetch" "+refs/pull/*/merge:refs/merge/$upstream/*"