Skip to content

Commit 6135453

Browse files
committed
set euo pipefail on all scripts
1 parent 7dee8d5 commit 6135453

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

pkgbuild/scripts/postinstall

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ LAUNCH_DAEMON_BINARY_PATH="/Applications/Coder Desktop.app/Contents/MacOS/com.co
1212
# Copy plist into system dir
1313
sudo cp "$LAUNCH_DAEMON_PLIST_SRC"/"$LAUNCH_DAEMON_PLIST_NAME" "$LAUNCH_DAEMON_PLIST_DEST"/"$LAUNCH_DAEMON_PLIST_NAME"
1414
# Set necessary permissions
15-
sudo chmod -R 755 "$LAUNCH_DAEMON_BINARY_PATH"
15+
sudo chmod 755 "$LAUNCH_DAEMON_BINARY_PATH"
1616
sudo chmod 644 "$LAUNCH_DAEMON_PLIST_DEST"/"$LAUNCH_DAEMON_PLIST_NAME"
1717
sudo chown root:wheel "$LAUNCH_DAEMON_PLIST_DEST"/"$LAUNCH_DAEMON_PLIST_NAME"
1818

scripts/upsert-dev-helper.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# /Applications/Coder/Coder Desktop.app, which is where the local build is
55
# installed.
66

7-
set -euox pipefail
7+
set -euxo pipefail
88

99
LAUNCH_DAEMON_PLIST_SRC="/Applications/Coder/Coder Desktop.app/Contents/Library/LaunchDaemons"
1010
LAUNCH_DAEMON_PLIST_DEST="/Library/LaunchDaemons"
@@ -19,7 +19,7 @@ sudo launchctl bootout "system/$LAUNCH_DAEMON_NAME" 2>/dev/null || true
1919
# Copy plist into system dir, with the path corrected to the local build
2020
sed 's|/Applications/Coder Desktop\.app|/Applications/Coder/Coder Desktop.app|g' "$LAUNCH_DAEMON_PLIST_SRC"/"$LAUNCH_DAEMON_PLIST_NAME" | sudo tee "$LAUNCH_DAEMON_PLIST_DEST"/"$LAUNCH_DAEMON_PLIST_NAME" >/dev/null
2121
# Set necessary permissions
22-
sudo chmod -R 755 "$LAUNCH_DAEMON_BINARY_PATH"
22+
sudo chmod 755 "$LAUNCH_DAEMON_BINARY_PATH"
2323
sudo chmod 644 "$LAUNCH_DAEMON_PLIST_DEST"/"$LAUNCH_DAEMON_PLIST_NAME"
2424
sudo chown root:wheel "$LAUNCH_DAEMON_PLIST_DEST"/"$LAUNCH_DAEMON_PLIST_NAME"
2525

0 commit comments

Comments
 (0)