File tree Expand file tree Collapse file tree 1 file changed +14
-14
lines changed
Expand file tree Collapse file tree 1 file changed +14
-14
lines changed Original file line number Diff line number Diff line change @@ -84,6 +84,20 @@ argUnexpected() {
8484 echo " UNEXPECTED ARGUMENT $1 "
8585}
8686
87+ argExists () {
88+ if [ -z ${argv["$1"]+abc} ]; then
89+ return 1
90+ else
91+ return 0
92+ fi
93+ }
94+
95+ argValue () {
96+ if argExists " $1 " ; then
97+ echo " ${argv["$1"]} "
98+ fi
99+ }
100+
87101argParse () {
88102 # Loop over all the argument chunks and determine if the argument type and value
89103 for argChunk in " ${argChunks[@]} " ; do
@@ -186,20 +200,6 @@ argParse() {
186200 echo " ARG: $k = ${argv[$k]} "
187201 done
188202
189- argExists () {
190- if [ -z ${argv["$1"]+abc} ]; then
191- return 1
192- else
193- return 0
194- fi
195- }
196-
197- argValue () {
198- if argExists " $1 " ; then
199- echo " ${argv["$1"]} "
200- fi
201- }
202-
203203 # Add the standard argc variable containing the number of arguments
204204 argc=${# argv[@]}
205205
You can’t perform that action at this time.
0 commit comments