summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
Diffstat (limited to 'tools')
-rwxr-xr-xtools/shman.sh9
1 files changed, 7 insertions, 2 deletions
diff --git a/tools/shman.sh b/tools/shman.sh
index 0c6dad3..3242329 100755
--- a/tools/shman.sh
+++ b/tools/shman.sh
@@ -306,11 +306,12 @@ main()
local source='Shell'
local manual='Shell Functions'
local shso=''
+ local base_dir='.'
local out_dir='.'
local tags=''
local f=
- while getopts 'hVs:m:S:d:t:' opt; do
+ while getopts 'hVs:m:S:b:d:t:' opt; do
case "${opt}" in
'h')
help
@@ -329,6 +330,9 @@ main()
'S')
shso="${OPTARG}"
;;
+ 'b')
+ base_dir="${OPTARG}"
+ ;;
'd')
out_dir="${OPTARG}"
;;
@@ -350,7 +354,8 @@ main()
fi
mkdir -p "${out_dir}"
for f in "${@}"; do
- parse_docs "${f}" "${source}" "${manual}" "${shso}" "${out_dir}"
+ parse_docs "${base_dir}/${f}" \
+ "${source}" "${manual}" "${shso}" "${out_dir}"
done
if [ -n "${tags}" ]; then
exec 3>&-