docs/cli/lock.md
mise lockmise lock [FLAGS] [TOOL]…src/cli/lock.rsCreate or refresh lockfile versions, checksums, and download URLs
Operates on the current config root, including tools declared by tasks. Existing
matching locked versions are preserved unless --bump re-resolves their selectors.
This command writes lockfiles without installing tools; --dry-run previews changes.
Use --platform for explicit targets. Otherwise mise uses lockfile_platforms
plus the current platform when that setting is configured, existing lockfile
platforms when available, or the common platform defaults for a new lockfile.
[TOOL]… — Tool(s) to update in lockfile
e.g.: node python
If not specified, all configured and task-specific tools will be updated-g --global — Target only global config lockfiles (~/.config/mise/mise.lock and system config)
By default, only the active project config root is locked
-j --jobs <JOBS> — Number of jobs to run in parallel
Values below 1 are treated as 1
Environment Variable: MISE_JOBS
-n --dry-run — Show what would be updated without making changes
-p --platform <PLATFORM> — Comma-separated list of platforms to target
e.g.: linux-x64,macos-arm64,windows-x64
If omitted, use lockfile_platforms, existing platforms, or common defaults
--bump — Re-resolve fuzzy version selectors against the latest available versions
By default, mise lock refreshes metadata for the currently locked versions.
With this flag, selectors like "latest", "lts", or prefixes like "20" are
re-resolved against the latest matching remote versions, so the lockfile
advances without installing anything. Config files are never modified:
exactly pinned versions resolve to themselves and stay unchanged
(use mise upgrade --bump to rewrite pins in mise.toml).
--json — Output version changes as JSON
Prints an array of objects describing lockfile version changes:
name, backend, lockfile, old_versions, new_versions.
Version lists keep config/lockfile order; they are not sorted.
Only version-level changes are reported: checksum/URL refreshes for
unchanged versions produce no entries, so plain mise lock --json
typically prints [] while still updating the lockfile.
Suppresses the human-readable output. Combine with --dry-run to
detect available updates without writing the lockfile.
--local — Update mise.local.lock instead of mise.lock
Use for tools defined in .local.toml configs
--minimum-release-age <MINIMUM_RELEASE_AGE> — Only lock versions released before this age or date
Supports absolute dates like "2024-06-01" and relative durations like "90d" or "1y". This only affects fuzzy version matches like "20" or "latest". Explicitly pinned versions like "22.5.0" are not filtered. Existing matching lockfile entries are preserved and are not downgraded solely by this flag.
--upgrade — Upgrade legacy lockfiles to the latest format
Existing unversioned lockfiles use format version 0 and are otherwise preserved to avoid unexpected lockfile drift. This flag upgrades them to the latest format with request-specific version bindings. Format upgrades always process every configured tool and cannot be combined with tool arguments.
-h --help — Print help
create or refresh the project lockfile
mise lock
update only node and python
mise lock node python
update only linux-x64 platform
mise lock --platform linux-x64
show what would be updated
mise lock --dry-run
re-resolve selectors like "latest" or "20" to the latest matching versions
mise lock --bump
list available updates as JSON without writing
mise lock --bump --dry-run --json
lock latest/fuzzy versions released before 2024-01-01
mise lock --minimum-release-age 2024-01-01
update mise.local.lock for local configs
mise lock --local
update only global config lockfiles
mise lock --global