You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Need to provide a general approach to support positional arguments in bash scripts.
To achieve this, two key points need to do:
Use || to concatenate all arg_set_opt_var entries with the tail to be arg_set_pos_var (TODO). To this end, we need arg_set_opt_var to return non-zero for no value assignment.
In arg_set_pos_var, use one global variable __POS_ARG_CURSOR to count the positional index, and assign positional argument value to global variables POS_ARG_VAR_XX where XX is expanded from __POS_ARG_CURSOR.
The text was updated successfully, but these errors were encountered:
Need to provide a general approach to support positional arguments in bash scripts.
To achieve this, two key points need to do:
Use
||
to concatenate allarg_set_opt_var
entries with the tail to bearg_set_pos_var
(TODO). To this end, we needarg_set_opt_var
to return non-zero for no value assignment.In
arg_set_pos_var
, use one global variable__POS_ARG_CURSOR
to count the positional index, and assign positional argument value to global variablesPOS_ARG_VAR_XX
whereXX
is expanded from__POS_ARG_CURSOR
.The text was updated successfully, but these errors were encountered: