diff --git a/bin/macos-brew-update.sh b/bin/macos-brew-update.sh index 35ec8db..0b543ab 100755 --- a/bin/macos-brew-update.sh +++ b/bin/macos-brew-update.sh @@ -2,7 +2,7 @@ set -euo pipefail if which brew >/dev/null 2>&1 ; then - if [ -e Brewfile ]; then + if [[ -e Brewfile ]] ; then set -x brew bundle set +x diff --git a/bin/macos-dock-tilesize.sh b/bin/macos-dock-tilesize.sh index e297240..660463a 100755 --- a/bin/macos-dock-tilesize.sh +++ b/bin/macos-dock-tilesize.sh @@ -4,7 +4,7 @@ set -eu print_cmd(){ while read LINE ; do - if [[ -n "$LINE" ]]; then + if [[ -n "$LINE" ]] ; then KEY=$( echo "$LINE" | tr -d ' ' | awk -F= '{print $1}' ) VAL=$( echo "$LINE" | tr -d ' ' | awk -F= '{print $2}' | tr -d ';' ) if echo "$VAL" | grep -q -E '^[0-9]+$' ; then diff --git a/bin/macos-ramdisk.sh b/bin/macos-ramdisk.sh index db5f698..6e8edb7 100755 --- a/bin/macos-ramdisk.sh +++ b/bin/macos-ramdisk.sh @@ -1,7 +1,7 @@ #!/usr/bin/env bash set -eux -if [[ ! -e /Volumes/RAMDisk/.metadata_never_index ]]; then +if [[ ! -e /Volumes/RAMDisk/.metadata_never_index ]] ; then set +x echo "=> Creating $1 GB /Volumes/RAMDisk..." set -x diff --git a/bin/macos-skhd.sh b/bin/macos-skhd.sh index d0cbf2c..c3d96cb 100644 --- a/bin/macos-skhd.sh +++ b/bin/macos-skhd.sh @@ -3,7 +3,7 @@ set -euo pipefail echo "=> Installing latest skhd..." -if [ -e ~/bin/skhd ]; then +if [[ -e ~/bin/skhd ]] ; then echo "=> An older version already installed at ~/bin/skhd" exit 1 else diff --git a/bin/macos-yabai.sh b/bin/macos-yabai.sh index 1e5c7c5..3923003 100644 --- a/bin/macos-yabai.sh +++ b/bin/macos-yabai.sh @@ -3,7 +3,7 @@ set -euo pipefail echo "=> Installing latest yabai..." -if [ -e ~/bin/yabai ]; then +if [[ -e ~/bin/yabai ]] ; then echo "=> An older version already installed at ~/bin/yabai" exit 1 else diff --git a/bin/setup-python3.sh b/bin/setup-python3.sh index fac3956..29c9e48 100755 --- a/bin/setup-python3.sh +++ b/bin/setup-python3.sh @@ -1,7 +1,7 @@ #!/usr/bin/env bash set -euo pipefail -if [ -e "$HOME/Library/Python/3.8/bin" ]; then +if [[ -e "$HOME/Library/Python/3.8/bin" ]] ; then export PATH=$PATH:$HOME/Library/Python/3.8/bin fi diff --git a/bin/yabai_cycle_clockwise.sh b/bin/yabai_cycle_clockwise.sh index 3ac2173..96f4a50 100644 --- a/bin/yabai_cycle_clockwise.sh +++ b/bin/yabai_cycle_clockwise.sh @@ -4,7 +4,7 @@ win=$(yabai -m query --windows --window last | jq '.id') while : ; do yabai -m window $win --swap prev &> /dev/null - if [[ $? -eq 1 ]]; then + if [[ $? -eq 1 ]] ; then break fi done