[install] Set a temporary GOPATH
This commit is contained in:
parent
b4c4a642ed
commit
24516bcf4d
6
install
6
install
@ -231,9 +231,13 @@ if [ -n "$binary_error" ]; then
|
|||||||
echo "No prebuilt binary for $archi ..."
|
echo "No prebuilt binary for $archi ..."
|
||||||
if command -v go > /dev/null; then
|
if command -v go > /dev/null; then
|
||||||
echo -n "Building binary (go get github.com/junegunn/fzf/src/fzf) ... "
|
echo -n "Building binary (go get github.com/junegunn/fzf/src/fzf) ... "
|
||||||
|
if [ -z "${GOPATH-}" ]; then
|
||||||
|
export GOPATH="${TMPDIR:-/tmp}/fzf-gopath"
|
||||||
|
mkdir -p "$GOPATH"
|
||||||
|
fi
|
||||||
if go get github.com/junegunn/fzf/src/fzf; then
|
if go get github.com/junegunn/fzf/src/fzf; then
|
||||||
echo "OK"
|
echo "OK"
|
||||||
link_fzf_in_path
|
cp "$GOPATH/bin/fzf" "$fzf_base/bin/"
|
||||||
else
|
else
|
||||||
echo "Failed to build binary ..."
|
echo "Failed to build binary ..."
|
||||||
install_ruby_fzf
|
install_ruby_fzf
|
||||||
|
Loading…
x
Reference in New Issue
Block a user