From da70d22064b9334ca2aec01536319ca5dc7cdb53 Mon Sep 17 00:00:00 2001 From: GRACENOBLE Date: Fri, 28 Aug 2026 13:05:50 +0300 Subject: [PATCH 1/3] fix: make backend watch and gradlew work on Linux/macOS - backend/Makefile: watch target hardcoded a powershell call, which fails outright on non-Windows shells. Replaced with a POSIX `command -v air` check that behaves the same across Windows (Git Bash/WSL), macOS, and Linux. - mobile/gradlew: was committed with mode 100644 (non-executable), since Windows doesn't track the Unix exec bit. This makes `./gradlew` fail with "Permission denied" for anyone cloning on Linux/macOS. Restored the executable bit. --- backend/Makefile | 10 ++++------ mobile/gradlew | 0 2 files changed, 4 insertions(+), 6 deletions(-) mode change 100644 => 100755 mobile/gradlew diff --git a/backend/Makefile b/backend/Makefile index 8a4ff52..e54f821 100644 --- a/backend/Makefile +++ b/backend/Makefile @@ -46,15 +46,13 @@ lint: # Live Reload watch: - @powershell -ExecutionPolicy Bypass -Command "if (Get-Command air -ErrorAction SilentlyContinue) { \ + @if command -v air > /dev/null 2>&1; then \ air; \ - Write-Output 'Watching...'; \ - } else { \ - Write-Output 'Installing air...'; \ + else \ + echo "Installing air..."; \ go install github.com/air-verse/air@latest; \ air; \ - Write-Output 'Watching...'; \ - }" + fi # ---- Migrations (goose) ---- diff --git a/mobile/gradlew b/mobile/gradlew old mode 100644 new mode 100755 From cbd5430abee249da24b1761454add425f626799a Mon Sep 17 00:00:00 2001 From: GRACENOBLE Date: Fri, 28 Aug 2026 13:08:40 +0300 Subject: [PATCH 2/3] fix: air bin path used Windows backslash, broke live-reload run step on Linux/macOS MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit .air.toml had bin = ".\\main.exe" — on Linux/macOS this resolves to a literal filename ".\main.exe" that never exists, since make build actually produces ./main.exe. air would build successfully but fail to exec the binary. Forward slash works identically on Windows. --- backend/.air.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/.air.toml b/backend/.air.toml index f127ea0..57db720 100644 --- a/backend/.air.toml +++ b/backend/.air.toml @@ -4,7 +4,7 @@ tmp_dir = "tmp" [build] args_bin = [] - bin = ".\\main.exe" + bin = "./main.exe" cmd = "make build" delay = 1000 exclude_dir = ["assets", "tmp", "vendor", "testdata", "node_modules"] From d7b05a167d00ffba80c35b2b3ef30baa874e2b76 Mon Sep 17 00:00:00 2001 From: GRACENOBLE Date: Fri, 28 Aug 2026 13:16:33 +0300 Subject: [PATCH 3/3] fix: resolve air's install path explicitly instead of relying on PATH go install doesn't modify PATH, so if $GOBIN/$GOPATH/bin isn't already on it, the fallback install-then-run branch would install air successfully and then fail with "air: command not found". Resolve GOBIN (falling back to GOPATH/bin, matching go install's own resolution order) and invoke that path directly. Addresses CodeRabbit review comment on #79. --- backend/Makefile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/backend/Makefile b/backend/Makefile index e54f821..a564acd 100644 --- a/backend/Makefile +++ b/backend/Makefile @@ -51,7 +51,9 @@ watch: else \ echo "Installing air..."; \ go install github.com/air-verse/air@latest; \ - air; \ + AIR_BIN="$$(go env GOBIN)"; \ + if [ -z "$$AIR_BIN" ]; then AIR_BIN="$$(go env GOPATH)/bin"; fi; \ + "$$AIR_BIN/air"; \ fi # ---- Migrations (goose) ----