From b342a2c9e17ed1e9ae2366d779cd605a37033b35 Mon Sep 17 00:00:00 2001 From: Marc Beninca Date: Tue, 8 Jul 2025 01:12:02 +0200 Subject: [PATCH] main/source --- sh/main.sh | 55 +++++++++++++++++++++++++++--------------------------- 1 file changed, 28 insertions(+), 27 deletions(-) diff --git a/sh/main.sh b/sh/main.sh index dd3628c..0476b0b 100755 --- a/sh/main.sh +++ b/sh/main.sh @@ -37,33 +37,6 @@ RWX_SELF_USER="${HOME}/${RWX_SELF_NAME}" # path to the entrypoint main file of the project RWX_MAIN_PATH="${RWX_ROOT_SYSTEM}/${RWX_MAIN_NAME}" -# ╭──────┬────────╮ -# │ main │ source │ -# ╰──────┴────────╯ - -# source code from file path -rwx_source() { - local root="${1}" - [ -d "${root}" ] || - return 1 - local file="${2}" - local count module modules - count=0 - __rwx_log "" \ - ". ${root}" - modules="$(rwx_find_shell "${root}" "${file}")" - while IFS= read -r module; do - count=$((count + 1)) - __rwx_log "$(printf "%02d" "${count}") ${module%.sh}" - # shellcheck disable=SC1090 - . "${root}/${module}" - # cache code - rwx_cache "${root}" "${module}" - done < cat rwx_cache() { local root="${1}" local module="${2}"