arg0
This commit is contained in:
parent
76176ae49f
commit
8e2cd2a867
1 changed files with 3 additions and 2 deletions
|
@ -125,7 +125,8 @@ rwx_main() {
|
|||
# user root
|
||||
rwx_source "${RWX_SELF_USER}"
|
||||
#
|
||||
case "${0}" in
|
||||
local argument="$(echo "${0}" | sed "s|^-||")"
|
||||
case "${argument}" in
|
||||
"bash" | \
|
||||
"dash" | \
|
||||
"sh")
|
||||
|
@ -144,7 +145,7 @@ rwx_main() {
|
|||
;;
|
||||
*)
|
||||
local function name
|
||||
name="$(basename "${0}")"
|
||||
name="$(basename "${argument}")"
|
||||
function="${RWX_SELF_COMMAND}${name}"
|
||||
"${function}" "${@}"
|
||||
;;
|
||||
|
|
Loading…
Reference in a new issue