summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorNeels Hofmeyr <neels@hofmeyr.de>2017-11-01 13:45:10 +0100
committerNeels Hofmeyr <neels@hofmeyr.de>2017-11-01 13:47:31 +0100
commit135f4485454ec9fa5717f30479693b24b12608b6 (patch)
treeda34b421f262f353285ae332a2d9bbb4f7999ae9 /scripts
parent64c82cdeafe65aa706f8779da5ff17033b0ffe97 (diff)
osmo-deps.sh: fix: add 'origin/' to branch, to properly update
If I have a git clone that once did 'checkout [-f] branch', and if then origin/branch gets updates, doing another 'checkout -f branch' only goes back to the local tracking-branch of origin/branch. We never pull in changes from origin/branch anymore as soon as a local branch exists. Always prepend 'origin/', so that 'checkout -f' goes into detached-HEAD state onto the newest fetched revision. Change-Id: Ia715a100b5beaf7e612c2c64cdad8819aa00c8bd
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/osmo-deps.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/osmo-deps.sh b/scripts/osmo-deps.sh
index 0610037..d5a724b 100755
--- a/scripts/osmo-deps.sh
+++ b/scripts/osmo-deps.sh
@@ -1,7 +1,7 @@
#!/bin/sh
set -ex
project="$1"
-branch="${2:-origin/master}"
+branch="origin/${2:-master}"
if ! test -d "$project";
then