-
Notifications
You must be signed in to change notification settings - Fork 467
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #5201 from filecoin-project/chore/tanlang/pre-down…
…load-go-mod Chore/tanlang/pre download go mod
- Loading branch information
Showing
2 changed files
with
42 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
#! bash | ||
# this script is used to pre download and install golang dependencies from source repos | ||
|
||
go env -w GOPROXY=https://goproxy.io,direct | ||
|
||
repos=(\ | ||
https://github.com/filecoin-project/venus.git \ | ||
https://github.com/filecoin-project/venus-messager.git \ | ||
https://github.com/ipfs-force-community/venus-gateway.git \ | ||
https://github.com/filecoin-project/venus-auth.git \ | ||
https://github.com/filecoin-project/venus-miner.git \ | ||
https://github.com/filecoin-project/venus-wallet.git \ | ||
https://github.com/filecoin-project/venus-market.git \ | ||
) | ||
|
||
mkdir -p /gomod/ | ||
cd /gomod/ | ||
|
||
function checkout { | ||
git clone $1 --depth 1 | ||
} | ||
|
||
for repo in ${repos[@]} | ||
do checkout $repo --depth 1 | ||
done | ||
|
||
for directory in $(ls) | ||
do | ||
if [ -d $directory ] | ||
then | ||
cd $directory | ||
go mod download -x | ||
cd .. | ||
echo $directory | ||
fi | ||
done | ||
|
||
rm -rf /gomod |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters