Skip to content

refactor(go): rename go_* settings to go.* namespace#8598

Merged
jdx merged 3 commits intojdx:mainfrom
jdbruijn:docs-go-default-packages-env
Apr 4, 2026
Merged

refactor(go): rename go_* settings to go.* namespace#8598
jdx merged 3 commits intojdx:mainfrom
jdbruijn:docs-go-default-packages-env

Conversation

@jdbruijn
Copy link
Copy Markdown
Contributor

@jdbruijn jdbruijn commented Mar 14, 2026

Rename all Go settings from flat go_* format to nested go.* namespace for consistency with other language settings (node.*, python.*, ruby.*).

Old setting names are preserved as deprecated aliases for backward compatibility.

Changes

  • go_default_packages_filego.default_packages_file
  • go_download_mirrorgo.download_mirror
  • go_repogo.repo
  • go_set_gobingo.set_gobin
  • go_set_gopathgo.set_gopath
  • go_set_gorootgo.set_goroot
  • go_skip_checksumgo.skip_checksum

Also adds documentation note about MISE_GO_DEFAULT_PACKAGES_FILE env var (original PR intent).

@gemini-code-assist
Copy link
Copy Markdown
Contributor

Summary of Changes

Hello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request improves the Go language documentation by adding a crucial detail about configuring the default packages file. It clarifies how users can override the default location for Go packages, enhancing the flexibility and usability of the mise tool for Go projects.

Highlights

  • Documentation Update: Added a note to the Go language documentation explaining how to specify a non-default location for the MISE_GO_DEFAULT_PACKAGES_FILE variable.
Changelog
  • docs/lang/go.md
    • Added a note about MISE_GO_DEFAULT_PACKAGES_FILE.
Activity
  • No specific activity (comments, reviews, progress) has been recorded for this pull request yet.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request correctly adds documentation for the MISE_GO_DEFAULT_PACKAGES_FILE setting, which was previously undocumented. The change is a valuable addition. I have a minor suggestion to improve the wording for better clarity and consistency with the rest of the documentation.

docs/lang/go.md Outdated
github.com/jesseduffield/lazygit
```

You can specify a non-default location of this file by setting a `MISE_GO_DEFAULT_PACKAGES_FILE` variable.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

For improved clarity and consistency, consider rephrasing this sentence to explicitly state that it's an environment variable and that it overrides the default path.

Suggested change
You can specify a non-default location of this file by setting a `MISE_GO_DEFAULT_PACKAGES_FILE` variable.
You can override the default location of this file by setting the `MISE_GO_DEFAULT_PACKAGES_FILE` environment variable.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FYI I kept it in-line with e.g. the Node.js.

@greptile-apps
Copy link
Copy Markdown
Contributor

greptile-apps bot commented Mar 14, 2026

Greptile Summary

This PR refactors Go-specific settings from a flat go_* naming convention to a nested go.* namespace, consistent with how other language settings are structured (e.g., node.*, python.*, ruby.*). The seven affected settings are each given a new canonical go.* form while the old names are preserved as hidden deprecated aliases.

Key changes:

  • settings.toml: Adds new [go.*] entries as canonical settings and converts old [go_*] entries to deprecated hidden aliases
  • src/config/settings.rs: Adds migration logic in set_hidden_configs to copy go_*go.* at runtime (same pattern as cargo_binstall)
  • src/plugins/core/go.rs: All references updated to use the new settings.go.* accessors — no functional change
  • schema/mise.json: Regenerated schema correctly reflects new go object with nested properties, and marks go_* flat keys as deprecated
  • e2e/config/test_config_ignore: Test updated to use go.download_mirror instead of go_download_mirror

The implementation is correct and consistent with existing codebase patterns. One minor issue with a misleading deprecation message is noted below.

Confidence Score: 5/5

Safe to merge — straightforward setting rename with no functional changes and correct backward-compatibility handling.

All remaining findings are P2 (a misleading deprecation string that has no runtime effect since deprecated_warn_at/deprecated_remove_at are not set). The refactoring correctly follows existing patterns, backward compatibility is preserved via hidden deprecated aliases, and the migration logic in set_hidden_configs matches the cargo_binstall precedent.

settings.toml line 753 has a misleading deprecated message for go.set_gopath, but it is purely cosmetic.

Important Files Changed

Filename Overview
settings.toml Adds new canonical [go.] settings and converts old [go_] entries to deprecated hidden aliases; the go.set_gopath deprecated message has a misleading 'goroot' reference
src/config/settings.rs Adds go_* → go.* migration in set_hidden_configs, consistent with cargo_binstall pattern; no warn_deprecated calls (intentional, no warn_at/remove_at dates defined)
src/plugins/core/go.rs All settings references updated to settings.go.* namespace; no functional changes, straightforward accessor rename
schema/mise.json Regenerated schema correctly adds go nested object with all seven properties and marks flat go_* keys as deprecated
e2e/config/test_config_ignore Test correctly updated to use go.download_mirror instead of go_download_mirror

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[User config: go_download_mirror / go.download_mirror] --> B{set_hidden_configs}
    B -->|go_default_packages_file set| C[copy → go.default_packages_file]
    B -->|go_download_mirror set| D[copy → go.download_mirror]
    B -->|go_repo set| E[copy → go.repo]
    B -->|go_set_gobin set| F[copy → go.set_gobin]
    B -->|go_set_gopath set| G[copy → go.set_gopath]
    B -->|go_set_goroot set| H[copy → go.set_goroot]
    B -->|go_skip_checksum set| I[copy → go.skip_checksum]
    C & D & E & F & G & H & I --> J[GoPlugin reads settings.go.*]
    J --> K[install / exec_env / get_tarball_url / etc.]
Loading

Reviews (2): Last reviewed commit: "docs(go): remove manual env var note" | Re-trigger Greptile

@jdx
Copy link
Copy Markdown
Owner

jdx commented Mar 14, 2026

the better fix would be to rename the setting go.default_packages_file

@jdbruijn
Copy link
Copy Markdown
Contributor Author

the better fix would be to rename the setting go.default_packages_file

I've tried to rename but ran into the following error, after changing the name in settings.toml and running mise run render. For me it's not worth the time TBH, sorry, to debug that issue and try to get it fixed and tested. I'll happily update the docs with changes, but I don't have time for the rename. LMK if you want doc changes. The environment variable is just another way to specify the file, which I just noticed missed the documentation. In the end I just have added the go:<package> syntax in the config file BTW, so that also makes this low priority for me.

[build]   --- stderr
[build]   /Users/me/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/aws-lc-sys-0.37.0/aws-lc/include/openssl/base.h:61:10: fatal error: 'stdlib.h' file not found
[build]
[build]   thread 'main' (9963053) panicked at /Users/me/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/aws-lc-sys-0.37.0/builder/sys_bindgen.rs:144:10:
[build]   Unable to generate bindings.: ClangDiagnostic("/Users/me/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/aws-lc-sys-0.37.0/aws-lc/include/openssl/base.h:61:10: fatal error: 'stdlib.h' file not found\n")

jdbruijn and others added 2 commits April 4, 2026 16:42
Move all Go-related settings from flat `go_*` format to nested `go.*`
namespace for consistency with other language settings (node.*, python.*, ruby.*).

Old setting names are preserved as deprecated aliases for backward compatibility.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@jdx jdx force-pushed the docs-go-default-packages-env branch from 3a1d12d to 90778f3 Compare April 4, 2026 16:46
@jdx jdx changed the title docs(go): add non-default packages note refactor(go): rename go_* settings to go.* namespace Apr 4, 2026
The `<Settings child="go" />` component now auto-renders all go.*
settings including default_packages_file, making the manual note redundant.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@jdx jdx enabled auto-merge (squash) April 4, 2026 17:13
@jdx jdx merged commit 079837a into jdx:main Apr 4, 2026
34 checks passed
jdx pushed a commit that referenced this pull request Apr 5, 2026
### 🚀 Features

- **(ci)** auto-convert external PRs to draft mode by @jdx in
[#8896](#8896)
- **(deps)** add `depends` field for user-specified tool dependencies by
@cprecioso in [#8776](#8776)
- **(dotnet)** support runtime-only installs by @fragon10 in
[#8524](#8524)
- **(npm)** apply install_before to transitive dependencies by @risu729
in [#8851](#8851)
- **(task)** allow passing arguments to task dependencies via
{{usage.*}} templates by @jdx in
[#8893](#8893)
- add options field to BackendListVersionsCtx by @esteve in
[#8875](#8875)

### 🐛 Bug Fixes

- **(backend)** filter PEP 440 .dev versions in fuzzy version matching
by @richardthe3rd in [#8849](#8849)
- **(ci)** update COPR BuildRequires rust version to match MSRV 1.88 by
@jdx in [#8911](#8911)
- **(ci)** add Ruby build dependencies to e2e Docker image by @jdx in
[#8910](#8910)
- **(ci)** add missing build dependencies to e2e Docker image by @jdx in
[#8912](#8912)
- **(ci)** add missing build dependencies to e2e Docker image by @jdx in
[#8914](#8914)
- **(ci)** use Node 24 LTS for corepack e2e test by @jdx in
[#8915](#8915)
- **(ci)** add libxml2 and pkg-config to e2e Docker image by @jdx in
[#8917](#8917)
- **(ci)** add libxml2-dev to e2e image and disable Swift SPM tests by
@jdx in [#8918](#8918)
- **(docs)** use sans-serif font for badges by @jdx in
[#8887](#8887)
- **(env)** parse --env=VALUE and -E=VALUE flag forms correctly by @jdx
in [#8889](#8889)
- **(exec)** use i64::from() for seccomp syscall numbers to survive
autofix by @jdx in [#8882](#8882)
- **(github)** preserve tool options like filter_bins when version
specified via CLI by @jdx in
[#8888](#8888)
- **(github)** use alias-specific options when tool_alias has its own
config by @jdx in [#8892](#8892)
- **(install)** add locked_verify_provenance setting and detect github
attestations at lock time by @jdx in
[#8901](#8901)
- **(lock)** prune stale version entries during filtered `mise lock
<tool>` runs by @altendky in
[#8599](#8599)
- **(python)** use lockfile URL for precompiled installs by @hehaoqian
in [#8750](#8750)
- **(release)** verify all build targets succeed before releasing by
@jdx in [#8886](#8886)
- **(ruby)** support build revisions for precompiled binaries in
mise.lock by @jdx in [#8900](#8900)
- **(swift)** fall back to Ubuntu 24.04 for unsupported Ubuntu versions
by @jdx in [#8916](#8916)
- **(zsh)** avoid duplicate trust warning after cd by @timothysparg in
[#8898](#8898)
- update flake.lock and add fix for rust-bindgen to default.nix by
@esteve in [#8874](#8874)
- when direnv diff is empty, do not try to parse it by @yaleman in
[#8857](#8857)
- skip trust check for plain .tool-versions in task list by @dportalesr
in [#8876](#8876)

### 🚜 Refactor

- **(go)** rename go_* settings to go.* namespace by @jdbruijn in
[#8598](#8598)

### 📚 Documentation

- **(tasks)** clarify task_config.includes behavior by @risu729 in
[#8905](#8905)

### 🧪 Testing

- **(ci)** run e2e tests inside Docker containers by @jdx in
[#8899](#8899)

### 📦️ Dependency Updates

- bump ubi from 0.8 to 0.9 by @jdx in
[#8906](#8906)
- bump zip from 3 to 8 by @jdx in
[#8908](#8908)
- update lockfile deps (hold back rattler) by @jdx in
[#8909](#8909)
- update bun.lock by @jdx in
[#8913](#8913)

### 📦 Registry

- add turso
([github:tursodatabase/turso-cli](https://github.com/tursodatabase/turso-cli))
by @kenn in [#8884](#8884)
- remove carp test by @jdx in
[#8894](#8894)

### Chore

- **(ci)** add workflow to warn PRs modifying vendored aqua-registry by
@jdx in [#8897](#8897)
- **(ci)** use github.token for draft conversion in auto-draft workflow
by @jdx in [#8903](#8903)
- remove deprecated settings older than 12 months by @jdx in
[#8904](#8904)

### New Contributors

- @dportalesr made their first contribution in
[#8876](#8876)
- @timothysparg made their first contribution in
[#8898](#8898)
- @hehaoqian made their first contribution in
[#8750](#8750)
- @jdbruijn made their first contribution in
[#8598](#8598)
- @cprecioso made their first contribution in
[#8776](#8776)
- @yaleman made their first contribution in
[#8857](#8857)
- @kenn made their first contribution in
[#8884](#8884)
- @fragon10 made their first contribution in
[#8524](#8524)

## 📦 Aqua Registry Updates

#### New Packages (6)

- [`ahkohd/oyo`](https://github.com/ahkohd/oyo)
- [`bellicose100xp/jiq`](https://github.com/bellicose100xp/jiq)
- [`kurama/dealve-tui`](https://github.com/kurama/dealve-tui)
- [`micahkepe/jsongrep`](https://github.com/micahkepe/jsongrep)
- [`textfuel/lazyjira`](https://github.com/textfuel/lazyjira)
- [`ubugeeei/vize`](https://github.com/ubugeeei/vize)

#### Updated Packages (1)

- [`sigstore/cosign`](https://github.com/sigstore/cosign)
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.

2 participants