Skip to content

Commit 63a4c27

Browse files
committed
Another fix for client build on windows
1 parent 9f17d61 commit 63a4c27

1 file changed

Lines changed: 5 additions & 14 deletions

File tree

client/Makefile

Lines changed: 5 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -4,20 +4,11 @@ VERSION := $(shell grep 'Version = ' cmd/root.go | head -1 | sed 's/.*"\(.*\)"/\
44

55
# Use bash as the Make recipe shell (required on Windows where the default
66
# shell cannot execute .sh scripts).
7-
# On Windows, "bash" can resolve to C:\Windows\System32\bash.exe (WSL launcher)
8-
# instead of Git Bash. Prefer Git Bash when available.
9-
ifeq ($(OS),Windows_NT)
10-
GIT_BASH := $(firstword $(wildcard $(ProgramW6432)/Git/bin/bash.exe) \
11-
$(wildcard $(ProgramFiles)/Git/bin/bash.exe) \
12-
$(wildcard $(PROGRAMFILES)/Git/bin/bash.exe))
13-
ifdef GIT_BASH
14-
SHELL := $(GIT_BASH)
15-
else
16-
SHELL := bash
17-
endif
18-
else
19-
SHELL := bash
20-
endif
7+
# On Windows with WSL installed, bare "bash" may resolve to the WSL launcher
8+
# (C:\Windows\System32\bash.exe) instead of Git Bash. CI workflows override
9+
# this with SHELL="$(which bash)" to guarantee Git Bash. For local Windows
10+
# dev use, ensure Git Bash appears before System32 on PATH.
11+
SHELL := bash
2112

2213
# Disable CGO to avoid Xcode/C compiler dependency
2314
export CGO_ENABLED = 0

0 commit comments

Comments
 (0)