GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — tweak - normalise unix-like identifiers to support git bash for windo… · asflex/opencode@36b48a4

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • install
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎install‎

Copy file name to clipboardExpand all lines: install
+8-4Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,14 @@ NC='\033[0m' # No Color
1010

1111
requested_version=${VERSION:-}
1212

13-
os=$(uname -s | tr '[:upper:]' '[:lower:]')
14-
if [[ "$os" == "darwin" ]]; then
15-
os="darwin"
16-
fi
13+
raw_os=$(uname -s)
14+
os=$(echo "$raw_os" | tr '[:upper:]' '[:lower:]')
15+
# Normalize various Unix-like identifiers
16+
case "$raw_os" in
17+
Darwin*) os="darwin" ;;
18+
Linux*) os="linux" ;;
19+
MINGW*|MSYS*|CYGWIN*) os="windows" ;;
20+
esac
1721
arch=$(uname -m)
1822

1923
if [[ "$arch" == "aarch64" ]]; then

0 commit comments

Comments
0 (0)
You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.