Skip to content

Commit b56bb5f

Browse files
committed
fix an issue where starting app in bg causes focus to move away from terminal
1 parent f59b224 commit b56bb5f

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

scripts/install.sh

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -359,9 +359,9 @@ install_macos() {
359359
cp -R "$app_bundle" "$MACOS_APP_DIR/"
360360

361361
mkdir -p "$HOME/.local/bin"
362-
local macos_bin="$MACOS_APP_DIR/$app_name/Contents/MacOS"
363362

364-
"$macos_bin/$DESKTOP_BINARY_NAME" --no-dashboard > /dev/null 2>&1 &
363+
open -g -a "$MACOS_APP_DIR/$app_name" --args --no-dashboard
364+
sleep 3
365365
}
366366

367367
# Install on Linux
@@ -389,6 +389,7 @@ install_linux() {
389389

390390
# Cleanup function - only removes files/dirs we created
391391
cleanup() {
392+
392393
if [ "$SUCCESS" = false ]; then
393394
error "Installation failed. Cleaning up..."
394395
fi
@@ -422,8 +423,6 @@ cleanup() {
422423
# =============================================================================
423424

424425
main() {
425-
log "Installing $CLI_NAME..."
426-
427426
# Parse command line arguments
428427
parse_args "$@"
429428

@@ -454,6 +453,8 @@ main() {
454453
download_and_verify "$download_url" "$filename"
455454
local downloaded_file="$DOWNLOAD_DIR/$filename"
456455

456+
log "Installing $CLI_NAME..."
457+
457458
# Install based on platform
458459
if [[ "$os" == "darwin" ]]; then
459460
install_macos "$downloaded_file"

0 commit comments

Comments
 (0)