fix(installer): guide Windows shell users to PowerShell (#1294) (#2048)

Recognize MINGW, MSYS, and Cygwin and print the exact PowerShell installer command.
Keep Darwin/Linux behavior unchanged and exit non-zero before downloading.
Cover shell dispatch and real Windows ARM64 Git Bash behavior.

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Colby Mchenry
2026-09-27 15:10:20 +00:00
committed by GitHub
parent 1008b34e69
commit d3671faf04
2 changed files with 42 additions and 0 deletions
+5
View File
@@ -34,6 +34,11 @@ arch="$(uname -m)"
case "$os" in
Darwin) os="darwin" ;;
Linux) os="linux" ;;
MINGW*|MSYS*|CYGWIN*)
echo "codegraph: on Windows, open PowerShell and run:" >&2
echo " irm https://raw.githubusercontent.com/colbymchenry/codegraph/main/install.ps1 | iex" >&2
exit 1
;;
*) echo "codegraph: unsupported OS '$os'." >&2; exit 1 ;;
esac
case "$arch" in