[M] Change in fuchsia/fuchsia[main]: [shell] Add option to integrate with shell using mise.

0 views
Skip to first unread message

'Adam Perry (Gerrit)' via owners-override

unread,
Jan 26, 2026, 12:31:47 PM (5 days ago) Jan 26
to Owners Override
Attention needed from Owners Override

Adam Perry has uploaded the change for review

Adam Perry would like Owners Override to review this change.

Commit message

[shell] Add option to integrate with shell using mise.

mise (https://mise.jdx.dev/about.html) is a tool and workflow
manager that does a large number of things. Here, we're only
using it as a substitute for adding global shell configuration
that's specific to a single Fuchsia checkout.

With either `mise activate` or a global shell integration, users
will always call the "right" fx/ffx etc. since mise will set up their
shell's PATH to point to the "local" one.

In this way mise is an alternative to direnv, but where direnv often
leaks state on leaving a directory mise's higher level configuration
syntax means it's much more reliable.

That said, I'm not attempting to add this option to the fuchsia.dev
docs since we don't (yet?) have a known-good way to install
mise from trusted sources.
Change-Id: I2a417e7bc6bdb216177e1b08edbfc6f13bcb79b1

Change diff

diff --git a/.mise/OWNERS b/.mise/OWNERS
new file mode 100644
index 0000000..f85e471
--- /dev/null
+++ b/.mise/OWNERS
@@ -0,0 +1,2 @@
+adam...@google.com
+crj...@google.com
diff --git a/.mise/README.md b/.mise/README.md
new file mode 100644
index 0000000..dc28e19
--- /dev/null
+++ b/.mise/README.md
@@ -0,0 +1,42 @@
+# mise on Fuchsia
+
+This mise config is an alternative to modifying your global shell config to
+be aware of Fuchsia. Instead you can add mise to your global shell config and
+it will automatically set up Fuchsia development tools when your shell's current
+directory is inside a Fuchsia checkout.
+
+See https://mise.jdx.dev/about.html for more information about mise.
+
+## Setup
+
+See https://mise.jdx.dev/getting-started.html.
+
+Once you can use `fx` without [setting up Fuchsia environment variables][fdev]
+then you're good to go.
+
+## IDE Agent Integration
+
+If you want mise to also update environment variables for shells launched by
+coding agents in e.g. Antigravity, then you can still convince the
+non-interactive editor terminals to activate mise if you set `BASH_ENV` to a
+script that activates mise.
+
+For example:
+
+```sh
+mkdir -p ~/.config/mise
+echo 'eval "$($HOME/.local/bin/mise activate bash)"' > ~/.config/mise/bash_env
+```
+
+Add the following to your `~/.bashrc` or `~/.profile` *before* either bails
+early for non-interactive shells:
+
+```sh
+export BASH_ENV="$HOME/.config/mise/bash_env"
+```
+
+After you restart your development machine the editor's agent should be able
+to run `fx`, `ffx`, etc. using mise the same way your interactive shells do.
+
+[fdev]: https://fuchsia.dev/fuchsia-src/get-started/get_fuchsia_source?hl=en#set-up-environment-variables
+[add shims]: https://mise.jdx.dev/ide-integration.html#adding-shims-to-path-default-shell
\ No newline at end of file
diff --git a/.mise/config.toml b/.mise/config.toml
new file mode 100644
index 0000000..5d90893
--- /dev/null
+++ b/.mise/config.toml
@@ -0,0 +1,14 @@
+# Copyright 2026 The Fuchsia Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+[env]
+# Used by most workflow tools.
+FUCHSIA_DIR = "{{ config_root }}"
+
+# This puts fx & ffx in PATH.
+_.path = "{{ config_root }}/.jiri_root/bin"
+
+# Used for symbolizing backtraces. Shell hacks are needed to ensure we pick up any configuration
+# from vendor/ devshell scripts too.
+DEBUGINFOD_URLS = "{{ exec(command=\"source $FUCHSIA_DIR/tools/devshell/lib/vars.sh && echo -n $DEBUGINFOD_URLS\") }}"

Change information

Files:
  • A .mise/OWNERS
  • A .mise/README.md
  • A .mise/config.toml
Change size: M
Delta: 3 files changed, 58 insertions(+), 0 deletions(-)
Open in Gerrit

Related details

Attention is currently required from:
  • Owners Override
Submit Requirements:
  • requirement is not satisfiedCode-Owners
  • requirement satisfiedCode-Review
  • requirement satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: newchange
Gerrit-Project: fuchsia
Gerrit-Branch: main
Gerrit-Change-Id: I2a417e7bc6bdb216177e1b08edbfc6f13bcb79b1
Gerrit-Change-Number: 1477222
Gerrit-PatchSet: 3
Gerrit-Owner: Adam Perry <adam...@google.com>
Gerrit-Reviewer: Adam Perry <adam...@google.com>
Gerrit-Reviewer: Christopher Johnson <crj...@google.com>
Gerrit-Reviewer: Owners Override <owners-...@fuchsia.dev>
Gerrit-Attention: Owners Override <owners-...@fuchsia.dev>

--
You received this message because you are subscribed to the Google Groups "owners-override" group.
To unsubscribe from this group and stop receiving emails from it, send an email to owners-overri...@fuchsia.dev.
To view this discussion visit https://groups.google.com/a/fuchsia.dev/d/msgid/owners-override/e8d80794ea1c8da04b9696ccf428e6597601dcc6-HTML%40fuchsia-review.googlesource.com.
unsatisfied_requirement
satisfied_requirement
open
diffy

'Adam Perry (Gerrit)' via owners-override

unread,
Jan 26, 2026, 12:31:50 PM (5 days ago) Jan 26
to Owners Override, Christopher Johnson, GI Try Builder, CQ Bot
Attention needed from Owners Override

Adam Perry voted

Commit-Queue+1
Fuchsia-Auto-Submit+1
Open in Gerrit

Related details

Attention is currently required from:
  • Owners Override
Submit Requirements:
  • requirement is not satisfiedCode-Owners
  • requirement satisfiedCode-Review
  • requirement satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: fuchsia
Gerrit-Branch: main
Gerrit-Change-Id: I2a417e7bc6bdb216177e1b08edbfc6f13bcb79b1
Gerrit-Change-Number: 1477222
Gerrit-PatchSet: 3
Gerrit-Owner: Adam Perry <adam...@google.com>
Gerrit-Reviewer: Adam Perry <adam...@google.com>
Gerrit-Reviewer: Christopher Johnson <crj...@google.com>
Gerrit-Reviewer: Owners Override <owners-...@fuchsia.dev>
Gerrit-Attention: Owners Override <owners-...@fuchsia.dev>
Gerrit-Comment-Date: Mon, 26 Jan 2026 17:31:44 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes

--
You received this message because you are subscribed to the Google Groups "owners-override" group.
To unsubscribe from this group and stop receiving emails from it, send an email to owners-overri...@fuchsia.dev.
To view this discussion visit https://groups.google.com/a/fuchsia.dev/d/msgid/owners-override/e8d80794ea1c8da04b9696ccf428e6597601dcc6-EmailReviewComments-HTML%40fuchsia-review.googlesource.com.
unsatisfied_requirement
satisfied_requirement
open
diffy

'Adam Barth (Gerrit)' via owners-override

unread,
Jan 26, 2026, 12:33:07 PM (5 days ago) Jan 26
to Adam Perry, Kevin Lindkvist, Owners Override, Christopher Johnson, GI Try Builder, CQ Bot
Attention needed from Adam Perry and Owners Override

Adam Barth voted Owners-Override+1

Owners-Override+1
Open in Gerrit

Related details

Attention is currently required from:
  • Adam Perry
  • Owners Override
Submit Requirements:
  • requirement satisfiedCode-Owners
  • requirement satisfiedCode-Review
  • requirement satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: fuchsia
Gerrit-Branch: main
Gerrit-Change-Id: I2a417e7bc6bdb216177e1b08edbfc6f13bcb79b1
Gerrit-Change-Number: 1477222
Gerrit-PatchSet: 3
Gerrit-Owner: Adam Perry <adam...@google.com>
Gerrit-Reviewer: Adam Barth <aba...@google.com>
Gerrit-Reviewer: Adam Perry <adam...@google.com>
Gerrit-Reviewer: Christopher Johnson <crj...@google.com>
Gerrit-Reviewer: Kevin Lindkvist <lind...@google.com>
Gerrit-Attention: Adam Perry <adam...@google.com>
Gerrit-Attention: Owners Override <owners-...@fuchsia.dev>
Gerrit-Comment-Date: Mon, 26 Jan 2026 17:33:02 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes

--
You received this message because you are subscribed to the Google Groups "owners-override" group.
To unsubscribe from this group and stop receiving emails from it, send an email to owners-overri...@fuchsia.dev.
To view this discussion visit https://groups.google.com/a/fuchsia.dev/d/msgid/owners-override/643c3bd4e7044bf17d029ac820b951702d4db94b-EmailReviewComments-HTML%40fuchsia-review.googlesource.com.
satisfied_requirement
open
diffy

'Kevin Lindkvist (Gerrit)' via owners-override

unread,
Jan 26, 2026, 12:33:13 PM (5 days ago) Jan 26
to Adam Perry, Owners Override, Christopher Johnson, GI Try Builder, CQ Bot
Attention needed from Adam Perry and Owners Override

Kevin Lindkvist voted Owners-Override+1

Owners-Override+1
Open in Gerrit

Related details

Attention is currently required from:
  • Adam Perry
  • Owners Override
Submit Requirements:
  • requirement satisfiedCode-Owners
  • requirement satisfiedCode-Review
  • requirement satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: fuchsia
Gerrit-Branch: main
Gerrit-Change-Id: I2a417e7bc6bdb216177e1b08edbfc6f13bcb79b1
Gerrit-Change-Number: 1477222
Gerrit-PatchSet: 3
Gerrit-Owner: Adam Perry <adam...@google.com>
Gerrit-Reviewer: Adam Perry <adam...@google.com>
Gerrit-Reviewer: Christopher Johnson <crj...@google.com>
Gerrit-Reviewer: Kevin Lindkvist <lind...@google.com>
Gerrit-Reviewer: Owners Override <owners-...@fuchsia.dev>
Gerrit-Attention: Adam Perry <adam...@google.com>
Gerrit-Attention: Owners Override <owners-...@fuchsia.dev>
Gerrit-Comment-Date: Mon, 26 Jan 2026 17:33:00 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes

--
You received this message because you are subscribed to the Google Groups "owners-override" group.
To unsubscribe from this group and stop receiving emails from it, send an email to owners-overri...@fuchsia.dev.
To view this discussion visit https://groups.google.com/a/fuchsia.dev/d/msgid/owners-override/f51716d2a10e9dd871f5861ed618e41d8c583b0e-EmailReviewComments-HTML%40fuchsia-review.googlesource.com.
satisfied_requirement
open
diffy

'CQ Bot (Gerrit)' via owners-override

unread,
Jan 26, 2026, 4:20:52 PM (5 days ago) Jan 26
to Adam Perry, Adam Barth, Kevin Lindkvist, Owners Override, Christopher Johnson, GI Try Builder

CQ Bot submitted the change

Change information

Commit message:
[shell] Add option to integrate with shell using mise.

mise (https://mise.jdx.dev/about.html) is a tool and workflow
manager that does a large number of things. Here, we're only
using it as a substitute for adding global shell configuration
that's specific to a single Fuchsia checkout.

With either `mise activate` or a global shell integration, users
will always call the "right" fx/ffx etc. since mise will set up their
shell's PATH to point to the "local" one.

In this way mise is an alternative to direnv, but where direnv often
leaks state on leaving a directory mise's higher level configuration
syntax means it's much more reliable.

That said, I'm not attempting to add this option to the fuchsia.dev
docs since we don't (yet?) have a known-good way to install
mise from trusted sources.
Change-Id: I2a417e7bc6bdb216177e1b08edbfc6f13bcb79b1
Commit-Queue: Adam Perry <adam...@google.com>
Owners-Override: Kevin Lindkvist <lind...@google.com>
Fuchsia-Auto-Submit: Adam Perry <adam...@google.com>
Owners-Override: Adam Barth <aba...@google.com>
Reviewed-by: Christopher Johnson <crj...@google.com>
Files:
  • A .mise/OWNERS
  • A .mise/README.md
  • A .mise/config.toml
Change size: M
Delta: 3 files changed, 58 insertions(+), 0 deletions(-)
Branch: refs/heads/main
Submit Requirements:
  • requirement satisfiedCode-Review: +2 by Christopher Johnson
Open in Gerrit
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: merged
Gerrit-Project: fuchsia
Gerrit-Branch: main
Gerrit-Change-Id: I2a417e7bc6bdb216177e1b08edbfc6f13bcb79b1
Gerrit-Change-Number: 1477222
Gerrit-PatchSet: 4
Gerrit-Owner: Adam Perry <adam...@google.com>
Gerrit-Reviewer: Adam Barth <aba...@google.com>
Gerrit-Reviewer: Adam Perry <adam...@google.com>
Gerrit-Reviewer: Christopher Johnson <crj...@google.com>
Gerrit-Reviewer: Kevin Lindkvist <lind...@google.com>
Gerrit-Reviewer: Owners Override <owners-...@fuchsia.dev>

--
You received this message because you are subscribed to the Google Groups "owners-override" group.
To unsubscribe from this group and stop receiving emails from it, send an email to owners-overri...@fuchsia.dev.
To view this discussion visit https://groups.google.com/a/fuchsia.dev/d/msgid/owners-override/731c8765a23afaab6a73c5f004aec497a519c1ae-HTML%40fuchsia-review.googlesource.com.
open
diffy
satisfied_requirement

'GI Roller (Gerrit)' via owners-override

unread,
Jan 26, 2026, 4:35:43 PM (5 days ago) Jan 26
to Adam Perry, CQ Bot, Adam Barth, Kevin Lindkvist, Owners Override, Christopher Johnson, GI Try Builder

Message from GI Roller

Open in Gerrit

Related details

Attention set is empty
Submit Requirements:
  • requirement satisfiedCode-Owners
  • requirement satisfiedCode-Review
  • requirement satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: fuchsia
Gerrit-Branch: main
Gerrit-Change-Id: I2a417e7bc6bdb216177e1b08edbfc6f13bcb79b1
Gerrit-Change-Number: 1477222
Gerrit-PatchSet: 4
Gerrit-Owner: Adam Perry <adam...@google.com>
Gerrit-Reviewer: Adam Barth <aba...@google.com>
Gerrit-Reviewer: Adam Perry <adam...@google.com>
Gerrit-Reviewer: Christopher Johnson <crj...@google.com>
Gerrit-Reviewer: Kevin Lindkvist <lind...@google.com>
Gerrit-Reviewer: Owners Override <owners-...@fuchsia.dev>
Gerrit-Comment-Date: Mon, 26 Jan 2026 21:35:38 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: No

--
You received this message because you are subscribed to the Google Groups "owners-override" group.
To unsubscribe from this group and stop receiving emails from it, send an email to owners-overri...@fuchsia.dev.
To view this discussion visit https://groups.google.com/a/fuchsia.dev/d/msgid/owners-override/7e537de1536b4c9709e73eb83d564044a0c93b95-EmailReviewComments-HTML%40fuchsia-review.googlesource.com.
satisfied_requirement
open
diffy
Reply all
Reply to author
Forward
0 new messages