File tree Expand file tree Collapse file tree 4 files changed +11
-2
lines changed
fixtures/workspaces/flag-args-with-dash Expand file tree Collapse file tree 4 files changed +11
-2
lines changed Original file line number Diff line number Diff line change @@ -17,3 +17,4 @@ bashly generate
1717./cli upload --help
1818./cli upload sourcefile
1919./cli upload sourcefile -u username
20+ ./cli upload sourcefile -u username -p ' '
Original file line number Diff line number Diff line change 11# :flag.case
22<%= aliases.join " | " %> )
33% if arg
4- if [[ $2 ]]; then
4+ if [[ -n ${2+x} ]]; then
55 args[<%= name %> ]="$2"
66 shift
77 shift
Original file line number Diff line number Diff line change @@ -116,3 +116,11 @@ missing required flag: --user, -u USER
116116args:
117117- ${args[source]} = sourcefile
118118- ${args[--user]} = username
119+ + ./cli upload sourcefile -u username -p ''
120+ # this file is located in 'src/upload_command.sh'
121+ # code for 'cli upload' goes here
122+ # you can edit it freely and regenerate (it will not be overwritten)
123+ args:
124+ - ${args[--password]} =
125+ - ${args[source]} = sourcefile
126+ - ${args[--user]} = username
Original file line number Diff line number Diff line change @@ -142,7 +142,7 @@ parse_requirements() {
142142
143143 # :flag.case
144144 --options | -o )
145- if [[ $2 ]]; then
145+ if [[ -n ${2+x} ]]; then
146146 args[--options]=" $2 "
147147 shift
148148 shift
You can’t perform that action at this time.
0 commit comments