fix compilation on Debian 7 (no git -C) (#18427)
* fix compilation on Debian 7 (no git -C) * address review * allow specify branch for testing unmerged csources * temporarily change csources checkout parameters for testing * Update tools/deps.nim Co-authored-by: Timothee Cour <timothee.cour2@gmail.com> * fix failure * Update config/build_config.txt * set proper git branch/hash Co-authored-by: Timothee Cour <timothee.cour2@gmail.com> Co-authored-by: Andreas Rumpf <rumpf_a@web.de>
This commit is contained in:
parent
252eea8cae
commit
b88496ac67
7 changed files with 20 additions and 9 deletions
|
|
@ -28,8 +28,13 @@ proc cloneDependency*(destDirBase: string, url: string, commit = commitHead,
|
|||
# from failing
|
||||
execRetry fmt"git clone -q {url} {destDir2}"
|
||||
if isGitRepo(destDir):
|
||||
execRetry fmt"git -C {destDir2} fetch -q"
|
||||
exec fmt"git -C {destDir2} checkout -q {commit}"
|
||||
let oldDir = getCurrentDir()
|
||||
setCurrentDir(destDir2)
|
||||
try:
|
||||
execRetry "git fetch -q"
|
||||
exec fmt"git checkout -q {commit}"
|
||||
finally:
|
||||
setCurrentDir(oldDir)
|
||||
elif allowBundled:
|
||||
discard "this dependency was bundled with Nim, don't do anything"
|
||||
else:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue