source/file
This commit is contained in:
parent
706847f746
commit
ebc41e8a53
1 changed files with 3 additions and 2 deletions
|
@ -38,7 +38,7 @@ RWX_MAIN_PATH="${RWX_ROOT_SYSTEM}/${RWX_MAIN_NAME}"
|
|||
# run initial steps
|
||||
rwx_main() {
|
||||
# source system root
|
||||
if ! rwx_source "${RWX_ROOT_SYSTEM}"; then
|
||||
if ! rwx_source "${RWX_ROOT_SYSTEM}" "${RWX_MAIN_NAME}"; then
|
||||
__rwx_log "Not a directory: ${RWX_ROOT_SYSTEM}"
|
||||
return 1
|
||||
fi
|
||||
|
@ -62,12 +62,13 @@ rwx_source() {
|
|||
local root="${1}"
|
||||
[ -d "${root}" ] ||
|
||||
return 1
|
||||
local file="${2}"
|
||||
local count module
|
||||
count=0
|
||||
__rwx_log "" \
|
||||
". ${root}"
|
||||
rwx_ifs_set
|
||||
for module in $(rwx_find_shell "${root}" "${RWX_MAIN_NAME}"); do
|
||||
for module in $(rwx_find_shell "${root}" "${file}"); do
|
||||
count=$((count + 1))
|
||||
__rwx_log "$(printf "%02d" "${count}") ${module%.sh}"
|
||||
module="${root}/${module}"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue