From 2368350d979824b3f37bbab702dc47202f8b469f Mon Sep 17 00:00:00 2001 From: Price Hiller Date: Sun, 31 Jul 2022 00:37:43 -0500 Subject: [PATCH] fix: handle pathing for autojump --- install.bash | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/install.bash b/install.bash index ed8b1d9..680b20c 100644 --- a/install.bash +++ b/install.bash @@ -131,10 +131,11 @@ install-cargo-binary() { install-autojump() { local install_path="${1}/autojump" - git clone "https://github.com/wting/autojump.git" "${install_path}" || return 1 + cd "$(mktemp -d)" + git clone "https://github.com/wting/autojump.git" "autojump" || return 1 ( - cd "${install_path}" - python3 "install.py" + cd "autojump" + python3 "install.py" -d "${install_path}" ) || return 1 } @@ -301,7 +302,7 @@ main() { print-break log "info" "Installing ${GREEN}autojump${RESET_BOLD}" - if ! install-autojump; then + if ! install-autojump "${DEPS_PATH}"; then log "error" "Failed to install ${GREEN}autojump${RESET_BOLD}" exit 1 fi