This commit is contained in:
Marc Beninca 2024-11-13 09:41:47 +01:00
parent 40c151d69e
commit e8c65c9821
Signed by: marc.beninca
GPG key ID: 9C7613450C80C24F
2 changed files with 5 additions and 5 deletions

View file

@ -1,13 +1,13 @@
#! /usr/bin/env bash #! /usr/bin/env bash
MAIN_SHELL_FILE="$(readlink --canonicalize-existing "${0}")" MAIN_USERS_FILE="$(readlink --canonicalize-existing "${0}")"
MAIN_SHELL_ROOT="$(dirname "${MAIN_SHELL_FILE}")" MAIN_USERS_ROOT="$(dirname "${MAIN_USERS_FILE}")"
main_link_bashrc() { main_link_bashrc() {
local file="/etc/bash.bashrc" local file="/etc/bash.bashrc"
rm --force "${file}" rm --force "${file}"
ln --symbolic "${MAIN_SHELL_FILE}" "${file}" ln --symbolic "${MAIN_USERS_FILE}" "${file}"
} }
# import modules # import modules
@ -33,4 +33,4 @@ main_import_modules() {
} }
# import modules # import modules
main_import_modules "${MAIN_SHELL_FILE}" main_import_modules "${MAIN_USERS_FILE}"

View file

@ -85,7 +85,7 @@ rescue_upload() {
"${user_host}" "${user_host}"
# upload root # upload root
rsync --delete --recursive \ rsync --delete --recursive \
"${MAIN_SHELL_ROOT}/" "${user_host}:/etc/bash/" "${MAIN_USERS_ROOT}/" "${user_host}:/etc/bash/"
# call setup # call setup
# TODO variable # TODO variable
ssh "${user_host}" -- "\ ssh "${user_host}" -- "\