Skip to content

fix(setup): persist Go PATH in shell profile after install#368

Merged
DorianZheng merged 1 commit intomainfrom
fix/setup-go-persist-path
Mar 12, 2026
Merged

fix(setup): persist Go PATH in shell profile after install#368
DorianZheng merged 1 commit intomainfrom
fix/setup-go-persist-path

Conversation

@DorianZheng
Copy link
Copy Markdown
Member

Summary

  • Follow-up to fix(setup): validate Go version and install from go.dev if too old #367 — the go.dev install puts Go in /usr/local/go/bin, but the export PATH only lasted for the setup script session
  • Subsequent shells (including make/cargo) still found the old distro Go
  • Now appends export PATH="/usr/local/go/bin:$PATH" to ~/.profile and ~/.bashrc (if they exist and don't already contain the entry)

Test plan

  • Run make setup on Linux with old Go — verify ~/.profile gets the PATH entry
  • Open a new terminal — go version should show the go.dev version
  • Run setup again — verify no duplicate entries in profile files

The go.dev install puts Go in /usr/local/go/bin, but the PATH export
only lasted for the setup script session. Subsequent shells still found
the old distro Go. Now appends PATH to ~/.profile and ~/.bashrc.
@DorianZheng DorianZheng merged commit 2868ba9 into main Mar 12, 2026
@DorianZheng DorianZheng deleted the fix/setup-go-persist-path branch March 12, 2026 06:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant