In wt line 31:
if [ -z $main_worktree ]; then
^------------^ SC2086: Double quote to prevent globbing and word splitting.
Did you mean:
if [ -z "$main_worktree" ]; then
In wt line 34:
echo Changing to worktree at: $main_worktree
^------------^ SC2086: Double quote to prevent globbing and word splitting.
Did you mean:
echo Changing to worktree at: "$main_worktree"
In wt line 35:
cd $main_worktree
^---------------^ SC2164: Use 'cd ... || exit' or 'cd ... || return' in case cd fails.
^------------^ SC2086: Double quote to prevent globbing and word splitting.
Did you mean:
cd "$main_worktree" || exit
In wt line 36:
exec $(echo $SHELL)
^------------^ SC2116: Useless echo? Instead of 'cmd $(echo foo)', just use 'cmd foo'.
^----^ SC2086: Double quote to prevent globbing and word splitting.
Did you mean:
exec $(echo "$SHELL")
In wt line 44:
curl -sL -o $TMP_PATH $download_url
^-------^ SC2086: Double quote to prevent globbing and word splitting.
^-----------^ SC2086: Double quote to prevent globbing and word splitting.
Did you mean:
curl -sL -o "$TMP_PATH" "$download_url"
In wt line 47:
chmod +x $TMP_PATH
^-------^ SC2086: Double quote to prevent globbing and word splitting.
Did you mean:
chmod +x "$TMP_PATH"
In wt line 48:
sudo mv $TMP_PATH $BINARY_PATH
^-------^ SC2086: Double quote to prevent globbing and word splitting.
^----------^ SC2086: Double quote to prevent globbing and word splitting.
Did you mean:
sudo mv "$TMP_PATH" "$BINARY_PATH"
In wt line 49:
rm -f $TMP_PATH
^-------^ SC2086: Double quote to prevent globbing and word splitting.
Did you mean:
rm -f "$TMP_PATH"
In wt line 57:
if [ $fetched_tag_name == $VERSION ]; then
^---------------^ SC2086: Double quote to prevent globbing and word splitting.
Did you mean:
if [ "$fetched_tag_name" == $VERSION ]; then
In wt line 66:
if [ -z $(command -v jq) ]; then
^--------------^ SC2046: Quote this to prevent word splitting.
In wt line 80:
if [ -z ${args[0]} ]; then
^--------^ SC2086: Double quote to prevent globbing and word splitting.
Did you mean:
if [ -z "${args[0]}" ]; then
In wt line 82:
elif [ ${args[0]} == "list" ]; then
^--------^ SC2086: Double quote to prevent globbing and word splitting.
Did you mean:
elif [ "${args[0]}" == "list" ]; then
In wt line 84:
elif [ ${args[0]} == "help" ]; then
^--------^ SC2086: Double quote to prevent globbing and word splitting.
Did you mean:
elif [ "${args[0]}" == "help" ]; then
In wt line 86:
elif [ ${args[0]} == "-" ]; then
^--------^ SC2086: Double quote to prevent globbing and word splitting.
Did you mean:
elif [ "${args[0]}" == "-" ]; then
In wt line 88:
elif [ ${args[0]} == "update" ]; then
^--------^ SC2086: Double quote to prevent globbing and word splitting.
Did you mean:
elif [ "${args[0]}" == "update" ]; then
In wt line 96:
echo Changing to worktree at: $directory
^--------^ SC2086: Double quote to prevent globbing and word splitting.
Did you mean:
echo Changing to worktree at: "$directory"
In wt line 97:
cd $directory
^-----------^ SC2164: Use 'cd ... || exit' or 'cd ... || return' in case cd fails.
^--------^ SC2086: Double quote to prevent globbing and word splitting.
Did you mean:
cd "$directory" || exit
In wt line 98:
exec $(echo $SHELL)
^------------^ SC2116: Useless echo? Instead of 'cmd $(echo foo)', just use 'cmd foo'.
^----^ SC2086: Double quote to prevent globbing and word splitting.
Did you mean:
exec $(echo "$SHELL")
In wt line 102:
if [ -z $directory ]; then
^--------^ SC2086: Double quote to prevent globbing and word splitting.
Did you mean:
if [ -z "$directory" ]; then
For more information:
https://www.shellcheck.net/wiki/SC2046 -- Quote this to prevent word splitt...
https://www.shellcheck.net/wiki/SC2164 -- Use 'cd ... || exit' or 'cd ... |...
https://www.shellcheck.net/wiki/SC2086 -- Double quote to prevent globbing ...