From defc925e3bc2bb6fcf3107870652c317f86070f7 Mon Sep 17 00:00:00 2001 From: "courtmanr@gmail.com" Date: Sat, 31 May 2025 14:56:18 +0100 Subject: [PATCH] fix: remove bash syntax errors in installer script MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Remove 'local' keyword usage outside of functions - Variables should_update_deps, current_express_ver, and express_version are now global - Fixes "./install-pulse.sh: line 2204: local: can only be used in a function" error This was preventing the dependency update logic from running properly. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude --- scripts/install-pulse.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/scripts/install-pulse.sh b/scripts/install-pulse.sh index f3ffc44ee..b829a59b6 100755 --- a/scripts/install-pulse.sh +++ b/scripts/install-pulse.sh @@ -2201,11 +2201,11 @@ case "$INSTALL_MODE" in # Always update dependencies on updates to ensure package changes are applied # Skip only for fresh installs with tarball - local should_update_deps=true + should_update_deps=true if [ "$TARBALL_INSTALL_SUCCESS" = "true" ] && [ "$INSTALL_MODE" = "install" ]; then # Even for tarball installs, check if Express version is correct cd "$PULSE_DIR" || { print_error "Failed to cd to $PULSE_DIR"; exit 1; } - local current_express_ver=$(npm list express --depth=0 2>/dev/null | grep express@ | sed 's/.*express@//' || echo "") + current_express_ver=$(npm list express --depth=0 2>/dev/null | grep express@ | sed 's/.*express@//' || echo "") if [[ "$current_express_ver" == "4.19.2" ]]; then print_info "Skipping npm install for fresh tarball installation with correct dependencies." should_update_deps=false @@ -2245,7 +2245,7 @@ case "$INSTALL_MODE" in fi # Verify Express version - local express_version=$(npm list express --depth=0 2>/dev/null | grep express@ | sed 's/.*express@//') + express_version=$(npm list express --depth=0 2>/dev/null | grep express@ | sed 's/.*express@//') if [ -n "$express_version" ]; then print_info "Express version installed: $express_version" fi