diff --git a/shell/main.sh b/shell/main.sh index 7925a6f..c8d2607 100644 --- a/shell/main.sh +++ b/shell/main.sh @@ -1,9 +1,5 @@ [ -n "${ENV}" ] || export ENV="/etc/shell/main.sh" -main_env_root() { - dirname "${ENV}" -} - main_link_bashrc() { local file="/etc/bash.bashrc" rm --force "${file}" diff --git a/shell/rescue/common.sh b/shell/rescue/common.sh index 49a9305..f33c5aa 100644 --- a/shell/rescue/common.sh +++ b/shell/rescue/common.sh @@ -66,11 +66,11 @@ rescue_upload() { "${user_host}" # upload root rsync --delete --recursive \ - "$(main_env_root)" "${user_host}:/etc" + "$(dirname "${ENV}")" "${user_host}:/etc" # call setup # TODO variable - ssh "${user_host}" -- "\ -. \"/etc/bash/main.sh\" ; rescue_configure \"${hostname}\"" + ssh "${user_host}" -- \ + ". \"${ENV}\" ; rescue_configure \"${hostname}\"" # create session ssh "${user_host}" -- byobu new-session -d # send keys