From c1a9332490c7a573ed894b2f034135c65d15d9c8 Mon Sep 17 00:00:00 2001 From: Din Tort Date: Mon, 27 Oct 2025 19:57:30 +0100 Subject: [PATCH] build: Remove hardcoded Homebrew path for solaar in macOS script The `create-macos-app.sh` script previously defaulted to a hardcoded Homebrew path for the `solaar` executable. This change removes the specific path, defaulting instead to `solaar`. This modification makes the script more flexible and robust. It allows the system's `PATH` to resolve the location of the `solaar` binary, accommodating various installation methods beyond a fixed Homebrew directory. The explicit check for the executable's existence is also removed, as the script will now rely on the command being available in the shell's environment, which is a more standard approach. --- tools/create-macos-app.sh | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/tools/create-macos-app.sh b/tools/create-macos-app.sh index 673166e4..f60a2904 100755 --- a/tools/create-macos-app.sh +++ b/tools/create-macos-app.sh @@ -3,14 +3,9 @@ set -euo pipefail APP_ROOT=${1:-/Applications/Solaar.app} -SOLAR_PATH=${SOLAR_PATH:-/opt/homebrew/bin/solaar} +SOLAR_PATH=${SOLAR_PATH:-solaar} ICON_SOURCE=${ICON_SOURCE:-share/solaar/icons/solaar.svg} -if [[ ! -x "${SOLAR_PATH}" ]]; then - echo "Error: Unable to execute ${SOLAR_PATH}. Set SOLAR_PATH to the solaar binary." >&2 - exit 1 -fi - case "${APP_ROOT}" in ""|"/"|".") echo "Error: Refusing to create app bundle at unsafe location: \"${APP_ROOT}\"" >&2