commit 03bbf9746e218bbdabb066cab0d46f9f2a1db411 from: Benjamin Stürz date: Wed Dec 27 22:49:35 2023 UTC Fix got-archive commit - 086c63cfd075493c777cd0b8e0400a8d24269de7 commit + 03bbf9746e218bbdabb066cab0d46f9f2a1db411 blob - ccf7f2afa09b047024cc66b4fc65ae3fb7986fd6 blob + c950a53c3e2acfd1120f7fe07d73eaf61c08a976 --- got-archive +++ got-archive @@ -23,10 +23,6 @@ tmpdir="/tmp/got-archive" while [ $# -ne 0 ]; do case "$1" in - -s) - strip=1 - shift - ;; -b) branch=$2 shift @@ -37,6 +33,10 @@ while [ $# -ne 0 ]; do shift shift ;; + -s) + strip=1 + shift + ;; -t) tmpdir=$2 shift @@ -69,7 +69,7 @@ mkdir -p "$tmpdir" if [ "$branch" ]; then cname="$name-$ver" - got checkout -q -b "$branch" "$repo" "$tmpdir/$cname" || die 3 "Error: failed to checkout" + got checkout -q -c "$branch" "$repo" "$tmpdir/$cname" || die 3 "Error: failed to checkout" else cname="$name" got checkout -q "$repo" "$tmpdir/$cname" || die 3 "Error: failed to checkout"