X-Git-Url: http://git.xonotic.org/?a=blobdiff_plain;f=misc%2Ftools%2Fall%2Fgit.subr;h=ac6594fbf8214f39f84974beec21906046bd1d21;hb=cf8cc7e9f8ac5457b6165198999dd3fd9ba33941;hp=5c8d53dc18094585f3304c830d4e41f67e7a813e;hpb=725fbdf921d0048b08af3fb77d3ffb26b6bf8352;p=xonotic%2Fxonotic.git diff --git a/misc/tools/all/git.subr b/misc/tools/all/git.subr index 5c8d53dc..ac6594fb 100644 --- a/misc/tools/all/git.subr +++ b/misc/tools/all/git.subr @@ -63,7 +63,7 @@ mirrorspeed() # now actually time it ( set +x - export REPO=$1 # so that the sh -c subshell can use it + export REPO="$1" # so that the sh -c subshell can use it { measure_time sh -c 'git ls-remote "$REPO" refs/heads/master >/dev/null 2>&1'; } 2>&1 >/dev/null | head -n 1 | cut -d ' ' -f 2 | tr -d . | sed 's,^0*,,' | grep . || echo 0 # unit: clock ticks (depends on what "time" returns ) @@ -459,9 +459,12 @@ case "$cmd" in msg "can skip the following paragraph and already use the repository." msg "" msg "To get access, your key has to be approved first. For that, visit" - msg "$devsite_url, then log in, create a \"New Issue\" on" - msg "the \"Support\" tracker in the \"Repository\" category where you" - msg "apply for access and paste the following output into the issue:" + msg "$gitsite_url, then log in, enter the" + msg "\"xonotic\" project, create an \"Issue\" tagged \"Repository Access\"" + msg "to apply for access and paste the following output into the issue:" + msg "" + msg "After that, go to your profile settings, \"SSH Keys\", \"Add SSH Key\"" + msg "and paste the following output:" msg "" msg "`cat ~/.ssh/id_rsa.pub`" elif [ -f ~/.ssh/id_dsa.pub ]; then @@ -471,9 +474,12 @@ case "$cmd" in msg "can skip the following paragraph and already use the repository." msg "" msg "To get access, your key has to be approved first. For that, visit" - msg "$devsite_url, then log in, create a \"New Issue\" on" - msg "the \"Support\" tracker in the \"Repository\" category where you" - msg "apply for access and paste the following output into the issue:" + msg "$gitsite_url, then log in, enter the" + msg "\"xonotic\" project, create an \"Issue\" tagged \"Repository Access\"" + msg "to apply for access and paste the following output into the issue:" + msg "" + msg "After that, go to your profile settings, \"SSH Keys\", \"Add SSH Key\"" + msg "and paste the following output:" msg "" msg "`cat ~/.ssh/id_dsa.pub`" else @@ -486,9 +492,12 @@ case "$cmd" in ssh-keygen -t rsa -b 4096 -f ~/.ssh/id_rsa msg "" msg "To get access, your key has to be approved first. For that, visit" - msg "$devsite_url, then log in, create a \"New Issue\" on" - msg "the \"Support\" tracker in the \"Repository\" category where you" - msg "apply for access and paste the following output into the issue:" + msg "$gitsite_url, then log in, enter the" + msg "\"xonotic\" project, create an \"Issue\" tagged \"Repository Access\"" + msg "to apply for access and paste the following output into the issue:" + msg "" + msg "After that, go to your profile settings, \"SSH Keys\", \"Add SSH Key\"" + msg "and paste the following output:" msg "" msg "`cat ~/.ssh/id_rsa.pub`" fi @@ -648,13 +657,10 @@ case "$cmd" in fi o=`git config xonotic.all.mirrorselection 2>/dev/null || true` git config xonotic.all.mirrorselection try_same - verbose git clone "$url" "$d0/$d" + verbose git clone --branch "$branch" "$url" "$d0/$d" git config xonotic.all.mirrorselection "$o" enter "$d0/$d" verbose fix_git_config "$url" "$pushurl" - if [ "$branch" != "master" ]; then - verbose git checkout --track -b "$branch" origin/"$branch" - fi cd "$d0" fi }