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
Copy file name to clipboardExpand all lines: README.md
+1-2Lines changed: 1 addition & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -193,7 +193,7 @@ The order the arguments are passed on the command line makes a difference
193
193
194
194
If you need to pass in non-argument stings along side your arguments you just need to add the end of arguments marker `--` and anything that follows wont be parsed as an argument but instead will be assigned to a numbered positional argument:
195
195
196
-
For example running: `./script.sh --arg1 --arg2 -- file1 file2 -f file5 fileN`
196
+
For example running: `./script.sh --arg1 --arg2 -- file1 file2 -f file5`
197
197
198
198
Will be parsed as:
199
199
@@ -203,7 +203,6 @@ Will be parsed as:
203
203
* Non-Argument: `file2` (accessible via `$2`)
204
204
* Non-Argument: `-f` (accessible via `$3`)
205
205
* Non-Argument: `file5` (accessible via `$4`)
206
-
* Non-Argument: `fileN` (accessible via `${N}`)
207
206
208
207
This way you can define arguments along side an arbitrary number of strings you may want to operate on at the same time!
0 commit comments