This commit is contained in:
Marc Beninca 2024-11-12 07:44:21 +01:00
parent f163abbd37
commit 976cb6e919
Signed by: marc.beninca
GPG key ID: 9C7613450C80C24F

View file

@ -4,14 +4,14 @@ MAIN_BASH_FILE="$(realpath "${BASH_SOURCE[0]}")"
MAIN_BASH_ROOT="$(dirname "${MAIN_BASH_FILE}")"
function main_link_bashrc {
main_link_bashrc() {
local file='/etc/bash.bashrc'
rm --force "${file}"
ln --symbolic "${MAIN_BASH_FILE}" "${file}"
}
# import modules
function main_import_modules {
main_import_modules() {
local file="${1}"
if [ -f "${file}" ] ; then
local path="$(realpath "${file}")"
@ -21,7 +21,7 @@ if [ -f "${file}" ] ; then
local module
for module in "${modules[@]}" ; do
if [ "${module}" != "${path}" ] ; then
source "${module}"
. "${module}"
fi
done
log_trace "${modules[@]}"