Created
December 23, 2018 20:20
-
-
Save GongT/6597b3776288d9a3f9078afd72a16068 to your computer and use it in GitHub Desktop.
parallel go get
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
#!/bin/bash | |
GOBIN=/usr/golang/bin/go | |
function go() { | |
if [ "$1" = "get" ]; then | |
shift | |
echo "run go get ::: $*" >&2 | |
parallel --will-cite -j 4 "$GOBIN" get -u -v ":::" "$@" | |
else | |
"$GOBIN" "$@" | |
fi | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment