Skip to contentSkip to conversation

download/git: don't require too-recent git

PATCH New Yann E. MORIN 2 participants 2 messages Apr 8, 2018

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 download/git: don't require too-recent git

git has supported -C only since 1.8.5, and some distros have not yet caught up after moe than 4 years...

Fall back to entering the directory.

Fixes:

    http://autobuild.buildroot.net/results/35f9f7a4adc6c2cad741079e4afdf1408c94703b
---
 support/download/git | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
support/download/git +3 -1
index 787b6bcca0..868dfad0dd 100755
@@ -47,7 +47,9 @@ git_cache="${dl_dir}/git"
 # fetch'ed later.
 if [ ! -d "${git_cache}" ]; then
     _git init "'${git_cache}'"
-    _git -C "'${git_cache}'" remote add origin "'${uri}'"
+    pushd "${git_cache}" >/dev/null
+    _git remote add origin "'${uri}'"
+    popd >/dev/null
 fi
 
 pushd "${git_cache}" >/dev/null
Signature · 1 line
2.14.1
#1 lore raw

PATCH 1/1 download/git: don't require too-recent git

Quoted 7 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Yann" == Yann E MORIN <[email protected]> writes:

git has supported -C only since 1.8.5, and some distros have not yet caught up after moe than 4 years...

Fall back to entering the directory.

Quoted 7 lines

Fixes:

    http://autobuild.buildroot.net/results/35f9f7a4adc6c2cad741079e4afdf1408c94703b

Committed, thanks.

Signature · 1 line
Bye, Peter Korsgaard