8b-is Go toolchain e2e setup (one-liner + Homebrew)
  • Shell 87.9%
  • Ruby 12.1%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
2026-10-28 23:34:22 +09:00
.github/workflows chore: add repo governance, badges, and CI 2026-10-27 11:55:06 +09:00
Formula feat(b8-go): add Apple Silicon unified-memory caveats & ensure 1b-go -> b8-go symlink in GOBIN 2026-10-27 16:10:14 +09:00
CHANGELOG.md chore: add repo governance, badges, and CI 2026-10-27 11:55:06 +09:00
CONTRIBUTING.md chore: add repo governance, badges, and CI 2026-10-27 11:55:06 +09:00
LICENSE feat: one-shot idempotent Go toolchain setup for 8b-is 2026-10-27 10:06:18 +09:00
README.md docs(readme): document ./setup-go.sh --check non-mutating verification mode 2026-10-28 23:34:22 +09:00
SECURITY.md chore: add repo governance, badges, and CI 2026-10-27 11:55:06 +09:00
setup-go.sh feat(b8-go): dynamic GOMEMLIMIT = 85% of unified memory 2026-10-27 16:22:08 +09:00
setup-langs.sh feat: add setup-langs.sh for Zig, Idris 2, and Perl 2026-10-27 14:18:52 +09:00

go-setup

License: MIT Shell tests

One-shot, idempotent Go toolchain setup for the 8b-is constellation, targeted at Apple Silicon Macs (M1 / M1 64GB).

One-liner

curl -fsSL https://raw.githubusercontent.com/8b-is/go-setup/main/setup-go.sh | bash

To inspect the detected Apple Silicon unified-memory profile (GOMEMLIMIT, GOGC, GOARCH=arm64, CGO_ENABLED=1) and 1b-go -> b8-go alias without modifying dotfiles or installing packages:

./setup-go.sh --check

What it does

  1. Installs Homebrew (if missing) and wires /opt/homebrew into PATH.
  2. Installs Go via brew install go.
  3. Lays out GOPATH=~/go, GOBIN=~/go/bin, GOPROXY=proxy.golang.org,direct and persists them into ~/.zprofile.
  4. Tunes Apple Silicon unified memory per node — GOARCH=arm64, CGO_ENABLED=1, GOGC=100, and GOMEMLIMIT sized to hw.memsize (50 GiB / 20 GiB / 10 GiB for the 64GB / 32GB / 16GB nodes).
  5. Symlinks 1b-go -> b8-go (the 1-bit / balanced ternary alias) into $GOBIN.
  6. Installs the repos' expected tooling: golangci-lint, staticcheck, gofumpt, air.
  7. Verifies go version and the environment.

Safe to re-run; every step is a no-op when already satisfied.

Homebrew

brew tap 8b-is/go-setup
brew install --HEAD b8-go    # also installs the 1b-go alias

The formula lives in Formula/b8-go.rb.

Languages (Zig · Idris · Perl)

Companion script for the other sovereign languages — idempotent, cross-platform (macOS via Homebrew, Linux via apt):

curl -fsSL https://raw.githubusercontent.com/8b-is/go-setup/main/setup-langs.sh | bash

Installs and verifies zig, idris2, and perl.

License

MIT — from love, from within.