Replies: 1 comment
-
Currently, there is no such feature. Automatic help generation is an optional feature that can be removed, so it does not parse the help strings. Therefore, the interface when implemented will probably look like the following. setup REST help:usage abbr:true args:problem_id,file_name -- \
"Usage: ${2##*/} [options...] <problem_id> <file_name>" '' \
'My problem file script' '' In this case, there doesn't seem to be much difference from the following code. problem_id=$1 file_name=$2 It is possible to generate the error message automatically, but you can also write it manually like this. # If no arguments are specified
problem_id=${1:?} # => bash: 1: parameter null or not set
problem_id=${1:?problem_id is not specified} # => bash: 1: problem_id is not specified I might do it if I could implement it simply, but I would like a little more reason. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Loving the tool for my script options, thank you for sharing your work. Wondering if there's any way to also set arguments?
For example, say in the parser definition I specify:
Currently, I have to set the following on my own:
Is there any way to tie it all together so they are automatically set? Thanks.
Beta Was this translation helpful? Give feedback.
All reactions