Fix go cache reliability in some edge cases

This commit is contained in:
Yaksh Bariya 2021-07-05 09:26:19 +05:30
parent 40aef7e5ea
commit 92f1afaa54
No known key found for this signature in database
GPG Key ID: F7486BA7D3D27581

View File

@ -50,12 +50,9 @@ termux_go_get() {
fi
if [ -d $TERMUX_PKG_CACHEDIR/go ]; then
cp $TERMUX_PKG_CACHEDIR/go $GOPATH -r
go get "$@"
else
go get "$@"
cp $GOPATH $TERMUX_PKG_CACHEDIR/go -r
fi
go get "$@"
cp $GOPATH $TERMUX_PKG_CACHEDIR/go -r
else
go get "$@"
fi