From e2cfbc54ad2092de3f7ae842f402baf05a16ece0 Mon Sep 17 00:00:00 2001 From: Conrad Irwin Date: Thu, 13 Jun 2024 07:59:28 -0600 Subject: [PATCH] Fix headless mode (#12960) This was broken by two things: 1. A merge conflict in the install.sh script leading to bad sh syntax 2. A return removed by accident when we refactored main Release Notes: - N/A --- crates/zed/src/main.rs | 1 + script/install.sh | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/crates/zed/src/main.rs b/crates/zed/src/main.rs index c3a39031fa..95a118edc5 100644 --- a/crates/zed/src/main.rs +++ b/crates/zed/src/main.rs @@ -500,6 +500,7 @@ fn handle_open_request(request: OpenRequest, app_state: Arc, cx: &mut let app_state = app_state.clone(); cx.spawn(move |cx| handle_cli_connection(connection, app_state, cx)) .detach(); + return; } if let Err(e) = init_ui(app_state.clone(), cx) { diff --git a/script/install.sh b/script/install.sh index b446fb771c..ac2d9d3a44 100755 --- a/script/install.sh +++ b/script/install.sh @@ -47,7 +47,7 @@ main() { } linux() { - if [[ -n "${ZED_BUNDLE_PATH:-}" ]]; then + if [ -n "${ZED_BUNDLE_PATH:-}" ]; then cp "$ZED_BUNDLE_PATH" "$temp/zed-linux-$arch.tar.gz" else echo "Downloading Zed"