feat: import proxy and remote support
This commit is contained in:
parent
c3bf916d8a
commit
ef360a3443
6
bin/gpr
6
bin/gpr
|
@ -5,12 +5,12 @@ set -e
|
||||||
# push current branch to ORIGIN and create a PR on UPSTREAM
|
# push current branch to ORIGIN and create a PR on UPSTREAM
|
||||||
# UPSTREAM must be a https github url
|
# UPSTREAM must be a https github url
|
||||||
if [ -n "$PROXY_HOST" ] && [ -n "$PROXY_PORT" ]; then
|
if [ -n "$PROXY_HOST" ] && [ -n "$PROXY_PORT" ]; then
|
||||||
export HTTPS_PROXY=http://$PROXY_HOST:$PROXY_PORT
|
export HTTP_PROXYS=http://$PROXY_HOST:$PROXY_PORT
|
||||||
|
echo HTTP_PROXYS=$HTTP_PROXYS
|
||||||
fi
|
fi
|
||||||
echo $HTTPS_PROXY
|
|
||||||
|
|
||||||
BRANCH=$(git branch --show-current)
|
BRANCH=$(git branch --show-current)
|
||||||
UPSTREAM_BRANCH=$(git remote show upstream | grep -oP 'HEAD branch: \K\w+')
|
UPSTREAM_BRANCH=$(HTTP_PROXYS=$HTTP_PROXYS git remote show upstream | grep -oP 'HEAD branch: \K\w+')
|
||||||
ORIGIN_URL=$(git remote get-url origin)
|
ORIGIN_URL=$(git remote get-url origin)
|
||||||
case "$ORIGIN_URL" in
|
case "$ORIGIN_URL" in
|
||||||
git@github.com:*)
|
git@github.com:*)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user