3
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

バージョン管理ツールとしてのmise

3
Last updated at Posted at 2025-11-27

miseとは

ミーズと読むらしいです。

miseは

  • asdfやvoltaなどのバージョン管理ツール
  • makefileやcargo-makeなどの環境変数・タスクランナー

を併せ持つツールです。
今回はバージョン管理ツールとして使うmiseを今更ながらまとめておきます。

install

わりとなんでもinstallできます。自分はbrewでinstallしました。

パスの貼り方がactivate かshimを選べます。

activateが推奨されていますが、自分は同じくnodeのバージョン管理の volta を使用する場面が移行後でもまだあり、
activateにするといろいろややこしくて嫌だったので、大人しくshimsを使っています

コマンド

インストール可能なプラグイン一覧

$ mise p ls-remote
# 1password
# 1password-cli
# aapt2
# act
# ...

ツールごとのバージョン一覧

$ mise ls-remote rust
# 0.1
# 0.2
# 0.3
# 0.4
# 0.5
# ...

カレントディレクトリ配下でのバージョン指定

$ mise use rust@1.91.1

latestも指定可能

$ mise use rust@latest

↑これらを実行すると実行したディレクトリにmise.tomlが作られます。

mise ls-remoteで出力されるプラグインだけでなく、
mise backends で設定されているソースからもとってこれる

$ mise backends
# aqua
# asdf
# cargo
# core
# dotnet
# gem
# github
# gitlab
# go
# npm
# pipx
# spm
# http
# ubi
# vfox

例えば、cargo install cargo-nextest で引っ張ってくるものは以下のようにinstallできる

$ mise use cargo:cargo-nextest@latest

グローバルに設定したい場合は -gオプションをつける。
~/.config/mise/config.toml が作られる

mise use -g rust@1.91.1

update

latestや@20とかメジャーバージョンを指定した場合などinstallされているものよりupdate可能なものがあれば以下のコマンドで一括updateできます。

mise upgrade

現状のinstall状況の確認

$ mise list
# Tool                                      Version           Source                      Requested
# aqua:jesseduffield/lazygit                0.56.0            ~/.config/mise/config.toml  latest
# awscli                                    2.31.35           ~/.config/mise/config.toml  latest
# bun                                       1.3.2             ~/.config/mise/config.toml  latest
# cargo:cargo-nextest                       0.9.111           ~/.config/mise/config.toml  latest
# cargo:sqlx-cli                            0.7.3             ~/.config/mise/config.toml  0.7.3
# ...

指定したバージョンで実行

指定したバージョンを掴んで実行できます。

mise exec python@3 -- python

mise.toml晒す

最後に自分のmise.tomlを晒して終わりです。

idiomatic_version_file_enable_tools を指定すると .node-versionsや.nvmrcなどもバージョン管理ファイルとして統合できるようになります。

[settings]
idiomatic_version_file_enable_tools = ["node"]

[tools]
"aqua:aws/aws-cli" = "latest"
"cargo:taplo-cli" = "latest"
deno = "2.1.4"
"go:github.com/denandz/sourcemapper" = "latest"
"go:github.com/google/yamlfmt/cmd/yamlfmt" = "latest"
lua = "latest"
node = "22.11.0"
"npm:@biomejs/biome" = "latest"
"npm:aws-cdk" = "latest"
"npm:prettier" = "latest"
pnpm = "latest"
python = "latest"
ruby = "3.3.6"
rust = "1.83.0"
rust-analyzer = "2024-10-14"
stylua = "latest"
uv = "latest"

最後に

より良い設定があればおしえてください。

3
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
3
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?