Migrating from asdf to mise (en place)
I’ve been using asdf
to manage my Ruby, node, and Python environments for a couple of years. I migrated to asdf
from rbenv
, and it kind of worked, but some shims never did their job, so I was a bit confused, but not soooo unhappy that I would actually investigate the issue. So whenever I buid and deployed my website, I went with
asdf exec bundle exec rake deploy
… which was a downgrade to type from rake deploy
with Ruby Bundler picking up the correct version automagically for years, but it wasn’t too bad given that my Emacs setup remembers the compilation commands anyway and offers auto-completion.
The typing got worse with home-row modifiers on my keyboard, because a roll-over on the left-hand side home row wouldn’t always actually type the letters “a”, “s”, “d”, and “f”, but trigger Ctrl-Opt-F or some such instead.
Now enter mise
, and oh boy is there a nice experience to be had! People seem to pour a lot of love into this tool.
-
Simple migration: Switching from
asdf
tomise
is simple thanks to the migration documentation. You can continue to use.tool-versions
files and don’t need to do much, really, but TOML configuration files are actually recommended. -
User-Friendly CLI: I immediately prefer
mise
’s command-line interface; theasdf
commands to install a language, package, plugin, whatever never clicked for me. I honestly can’t tell why. I want toasdf uninstall
but that doesn’t exist as the inverse operation toinstall, for example.
mise` offers that. -
Editor integration (instead of shims): Shims are basically shell scripts in your
$PATH
that are stand-ins for the actual commands you want to run, so thatrake deploy
is resolved to arake
shim which runsasdf exec
under the hood, for example. That was brittle for me in the past. Instead of using shims, I use the Emacs packagemise.el
and triedglobal-mise-mode
(which takes a while to load). But that essentially provides aliases for me that usemise
under the hood:$ which rake /Users/ctm/.local/share/mise/installs/ruby/3.4.4/bin/rake
(There are plug-ins for IntelliJ and VS Code and NeoVim, too, in case you’re struggling with tasteful life choices.)
Read Tuist’s “A Mise guide for Swift developers” for a condensed overview.