Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunio C Hamano <junkio@cox.net>2005-08-20 13:52:24 +0400
committerJunio C Hamano <junkio@cox.net>2005-08-25 03:50:49 +0400
commitac4b0cff00b7629657e61a1d6e1f1a1250d03198 (patch)
tree26b5247b7614786144bba93c340a8547b50f18a7 /git-push-script
parentd998a0895fc20c03007d8b2a74b78b37e1cdfaba (diff)
[PATCH] Start adding the $GIT_DIR/remotes/ support.
All the necessary parsing code is in git-parse-remote-script; update git-push-script to use it. Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'git-push-script')
-rwxr-xr-xgit-push-script28
1 files changed, 6 insertions, 22 deletions
diff --git a/git-push-script b/git-push-script
index 70fa9684a5..5fa5af2af8 100755
--- a/git-push-script
+++ b/git-push-script
@@ -20,8 +20,6 @@ do
-*)
die "Unknown parameter $1" ;;
*)
- remote="$1"
- shift
set x "$@"
shift
break ;;
@@ -29,27 +27,13 @@ do
shift
done
-case "$remote" in
-*:* | /* | ../* | ./* )
- # An URL, host:/path/to/git, absolute and relative paths.
- ;;
-* )
- # Shorthand
- if expr "$remote" : '..*/..*' >/dev/null
- then
- # a short-hand followed by a trailing path
- shorthand=$(expr "$remote" : '\([^/]*\)')
- remainder=$(expr "$remote" : '[^/]*\(/.*\)$')
- else
- shorthand="$remote"
- remainder=
- fi
- remote=$(sed -e 's/#.*//' "$GIT_DIR/branches/$remote") &&
- expr "$remote" : '..*:' >/dev/null &&
- remote="$remote$remainder" ||
- die "Cannot parse remote $remote"
- ;;
+. git-parse-remote-script
+remote=$(get_remote_url "$@")
+case "$has_all" in
+--all) set x ;;
+'') set x $(get_remote_refs_for_push "$@") ;;
esac
+shift
case "$remote" in
http://* | https://* | git://* | rsync://* )