use GIT_DIR env var

pull/273/head
Frostebite 2021-07-12 23:12:18 +01:00
parent 3ebf2bfd1a
commit e1c24d67e3
4 changed files with 10 additions and 8 deletions

2
dist/index.js vendored
View File

@ -2109,7 +2109,7 @@ class RemoteBuilder {
echo "after making directories" echo "after making directories"
tree ${buildPathFull} tree ${buildPathFull}
# #
echo "Cloning utility repositories required for building:" echo "Cloning utility repositories required for building"
git clone --branch "remote-builder/unified-providers" ${repo} ${builderPathFull} git clone --branch "remote-builder/unified-providers" ${repo} ${builderPathFull}
git clone ${repo2} ${steamPathFull} git clone ${repo2} ${steamPathFull}
# #

2
dist/index.js.map vendored

File diff suppressed because one or more lines are too long

View File

@ -4,16 +4,18 @@ repoPathFull=$1
cloneUrl=$2 cloneUrl=$2
githubSha=$3 githubSha=$3
export GIT_DIR=$repoPathFull
echo '' echo ''
echo "Cloning the repository being built:" echo "Cloning the repository being built:"
# DISABLE LFS # DISABLE LFS
git config --global filter.lfs.smudge "git-lfs smudge --skip -- %f" git config --global filter.lfs.smudge "git-lfs smudge --skip -- %f"
git config --global filter.lfs.process "git-lfs filter-process --skip" git config --global filter.lfs.process "git-lfs filter-process --skip"
# Init new repo and setup origin # Init new repo and setup origin
git init --work-tree=$repoPathFull git init $repoPathFull
git remote add origin $cloneUrl --work-tree=$repoPathFull git remote add origin $cloneUrl
# Get remote version # Get remote version
git fetch --work-tree=$repoPathFull origin git fetch origin
git reset --work-tree=$repoPathFull --hard $githubSha git reset --hard $githubSha
git lfs ls-files --all --work-tree=$repoPathFull git lfs ls-files --all
echo '' echo ''

View File

@ -118,7 +118,7 @@ class RemoteBuilder {
echo "after making directories" echo "after making directories"
tree ${buildPathFull} tree ${buildPathFull}
# #
echo "Cloning utility repositories required for building:" echo "Cloning utility repositories required for building"
git clone --branch "remote-builder/unified-providers" ${repo} ${builderPathFull} git clone --branch "remote-builder/unified-providers" ${repo} ${builderPathFull}
git clone ${repo2} ${steamPathFull} git clone ${repo2} ${steamPathFull}
# #