Repository navigation
A new mise_env input sets the mise environment for the action and exports MISE_ENV to every later step in the job. mise run and mise x in later steps now load the same mise.<env>.toml configs that the action installed and cached.
Added
-
mise_envinput. Before this change, settingMISE_ENVin the action step'senv:only applied inside the action. Later steps never saw it and quietly fell back to the base config. Job-levelenv:worked, but composite actions that pick the environment from their own inputs had to writeMISE_ENVtoGITHUB_ENVthemselves, and security linters such as zizmor flag that. The new input handles the export for you:- uses: jdx/mise-action@v5 with: mise_env: ci # loads mise.ci.toml on top of mise.toml - run: mise run test # also runs with MISE_ENV=ci
In a composite action:
runs: using: composite steps: - uses: jdx/mise-action@v5 with: mise_env: ${{ inputs.haskell == 'true' && 'ci' || 'ci-no-haskell' }}
The input accepts one or more environments, such as
ciorci,linux. The action exports it before computing the cache key, so{{mise_env}}in a customcache_key,mise install, and later steps all use the same value. IfMISE_ENVis already set, the input takes priority, the same waymise_dirtakes priority overMISE_DATA_DIR. If you leave the input unset, nothing changes, and a step-levelMISE_ENVstill isn't exported. (#745 by @jdx with @veimox and @cprecioso, closes #447)
Full Changelog: v5.2.10...v5.3.0