Skip to content

Commit 7701728

Browse files
committed
Escape arguments when searching for commands
1 parent 27fd2b6 commit 7701728

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

flutterw

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ FLUTTER_EXIT_STATUS=$?
7979
if [ $FLUTTER_EXIT_STATUS -eq 0 ]; then
8080

8181
# ./flutterw channel CHANNEL
82-
if echo $@ | grep -q "channel"; then
82+
if echo "$@" | grep -q "channel"; then
8383
# make sure .gitmodules is updated as well
8484
CHANNEL=${2} # second arg
8585
git config -f .gitmodules submodule.$FLUTTER_SUBMODULE_NAME.branch $CHANNEL
@@ -89,7 +89,7 @@ if [ $FLUTTER_EXIT_STATUS -eq 0 ]; then
8989
fi
9090

9191
# ./flutterw upgrade
92-
if echo $@ | grep -q "upgrade"; then
92+
if echo "$@" | grep -q "upgrade"; then
9393
# makes sure nobody forgets to do commit the changed submodule
9494
git add $FLUTTER_SUBMODULE_NAME
9595
# flutter packages get runs automatically. Stage those changes as well

0 commit comments

Comments
 (0)