File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -23,17 +23,18 @@ instance_name() {
2323 grep -B 5 " ^\s*url\s*=\s*http\(s\)*://$host " ~ /.python-gitlab.cfg | grep " ^\[" | tail -n 1 | sed -e ' s#\[\(.\+\)\]#\1#'
2424}
2525
26- if [ " x$1 " = " x--git-remote" ]; then
26+ remote=$( git config --local gitlab.remote)
27+ [ -n " $remote " ] || remote=$( git remote)
28+ if [ " x$1 " = " x--remote" ]; then
2729 remote=$2
2830 shift 2
2931fi
30- [ -n " $remote " ] || remote=$( git remote)
3132if [ -z " $remote " ]; then
3233 echo " No remotes found in repository"
3334 exit 1
3435fi
3536if [ $( echo $remote | wc -w) -gt 1 ]; then
36- echo " Multiple remotes found, specify a remote using --git- remote REMOTE"
37+ echo " Multiple remotes found, specify a remote using --remote REMOTE"
3738 exit 1
3839fi
3940
Original file line number Diff line number Diff line change 22
33# TODO:
44# check args for cfg file
5- if [ " x$1 " = " x--git- remote" ]; then
5+ if [ " x$1 " = " x--remote" ]; then
66 git_repo=" $1 $2 "
77 shift 2
88fi
You can’t perform that action at this time.
0 commit comments