diff --git a/scripts/genhelp.sh b/scripts/genhelp.sh index 0ecb6603..e9d8412e 100755 --- a/scripts/genhelp.sh +++ b/scripts/genhelp.sh @@ -1,6 +1,12 @@ #!/bin/bash set -e +command -v gfind >/dev/null && +command -v gsed >/dev/null && +command -v gsort >/dev/null && { + sed() { gsed "$@"; } +} + [ -e make-sfx.sh ] || cd scripts [ -e make-sfx.sh ] && [ -e deps-docker ] || { echo cd into the scripts folder first diff --git a/scripts/help2html.py b/scripts/help2html.py index f39332ed..2ddb88be 100755 --- a/scripts/help2html.py +++ b/scripts/help2html.py @@ -37,7 +37,12 @@ def cnv(src): hostname = str(socket.gethostname()).split(".")[0] yield '' - yield '
' + yield '' skip_sfx = False in_sfx = 0 in_salt = 0 @@ -104,6 +109,15 @@ def cnv(src): ln = re.sub(r">[0-9]{1,2}\.[0-9]<", ">dynamic<", ln) if t != ln: in_th_ram_max = 0 + m = re.search(r"^# (.* help page)(.*)", ln) + if m: + zs1, zs2 = m.groups() + zs3 = zs1.replace(" ", "-") + ln = '