This commit is contained in:
Marc Beninca 2025-01-13 07:02:35 +01:00
parent 149cc47894
commit 53f8c5d91c
Signed by: marc.beninca
GPG key ID: 9C7613450C80C24F

View file

@ -1,3 +1,24 @@
# meta doc
rwx_doc() {
local name="${1}"
[ -n "${name}" ] || return
local doc line module
rwx_ifs_set
for module in $(rwx_find_shell "${RWX_ROOT_SYSTEM}"); do
while read -r line; do
case "${line}" in
"#"*) doc="${doc}${line}" ;;
"${name}() {")
echo "${doc}"
return
;;
*) doc="" ;;
esac
done < "${RWX_ROOT_SYSTEM}/${module}"
done
rwx_ifs_unset
}
# ╭──────┬───────╮ # ╭──────┬───────╮
# │ self │ check │ # │ self │ check │
# ╰──────┴───────╯ # ╰──────┴───────╯