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
|
# run initial steps
|
||||||
rwx_main() {
|
rwx_main() {
|
||||||
# source system root
|
# 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}"
|
__rwx_log "Not a directory: ${RWX_ROOT_SYSTEM}"
|
||||||
return 1
|
return 1
|
||||||
fi
|
fi
|
||||||
|
@ -62,12 +62,13 @@ rwx_source() {
|
||||||
local root="${1}"
|
local root="${1}"
|
||||||
[ -d "${root}" ] ||
|
[ -d "${root}" ] ||
|
||||||
return 1
|
return 1
|
||||||
|
local file="${2}"
|
||||||
local count module
|
local count module
|
||||||
count=0
|
count=0
|
||||||
__rwx_log "" \
|
__rwx_log "" \
|
||||||
". ${root}"
|
". ${root}"
|
||||||
rwx_ifs_set
|
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))
|
count=$((count + 1))
|
||||||
__rwx_log "$(printf "%02d" "${count}") ${module%.sh}"
|
__rwx_log "$(printf "%02d" "${count}") ${module%.sh}"
|
||||||
module="${root}/${module}"
|
module="${root}/${module}"
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue