mise-en-place

website·Indexed 39 days ago

https://mise.jdx.dev

A CLI for managing development tools, environment variables, and tasks. Includes guidance on configuration, bootstrapping machine setups, and the vfox plugin system.

Tokens
6.2K
Snippets
40
Records
71
Agent score
74%

What's inside mise

  1. Overview of mise-en-place

    mise-en-place is a single CLI tool used to manage development tools, environment variables, and tasks. It allows developers to maintain consistent environments across local development and Continuous Integration (CI) by using a shared configuration file (mise.toml).
  2. Use vfox as the recommended plugin system for mise

    vfox is the recommended plugin system for mise. It is designed for cross-platform support, includes built-in modules, and utilizes a modern hook-based architecture.
  3. Manage language runtimes with mise

    mise provides built-in support for managing multiple versions of the following languages, often replacing the need for language-specific version managers:

    • Node.js: Alternative to nvm, volta, or fnm.
    • Python: Alternative to pyenv; integrates with uv and supports automatic virtual environment creation.
    • Ruby: Alternative to rvm or rbenv.
    • Java: Alternative to sdkman.
    • Rust: Manages rustup under the hood to install toolchains, components, and targets.
    • Others: Go, Bun, Deno, Elixir, Erlang, Swift, and Zig.
  4. Inspect tool paths and information with mise

    Use these commands to locate tools and their executables:

    • mise where: Display the installation path for a tool.
    • mise which: Show the path a tool's executable resolves to.
    • mise tool: Show detailed information about a specific tool.
    mise where node
    mise which node
    mise tool node
  5. Manage development tools with mise

    mise is a CLI tool used to install development tools and manage their versions on a per-project basis. It allows developers to maintain multiple versions of languages and tools (such as Node.js, Python, Ruby, and Go) on a single machine and declare specific version requirements for each project.
  6. Manage dotfiles and configuration history

    mise can track dotfiles (e.g., ~/.zshrc, ~/.gitconfig). It saves versions of tracked configuration files in Git locally, allowing users to inspect changes and restore earlier versions without needing a remote repository immediately.
  7. Manage tasks in a monorepo

    mise supports monorepo architectures using target path syntax. This allows a single repository to contain multiple projects, each with its own mise.toml file, while still being manageable from a central point.
  8. Develop custom mise plugins

    mise uses a Lua-based plugin system to extend functionality. There are four primary types of plugins:

    • Tool Plugins: Manage a single versioned tool using Lua lifecycle hooks.
    • Backend Plugins: Manage multiple tools (use the mise-backend-plugin-template for a starting point).
    • Environment Plugins: Provide environment variables and PATH entries without installing a tool (e.g., for secret managers).
    • Package Plugins: Lua-based vfox plugins that implement machine-global managers for bootstrap.packages.
  9. Run project diagnostics with mise doctor

    The command mise doctor project executes named checks defined in the project's configuration. This is used to verify requirements that tool versions alone cannot satisfy, such as verifying if a compiler is functioning correctly.
    mise doctor project
  10. Integrate mise into Continuous Integration (CI) pipelines

    To ensure CI environments match development environments, use the same mise.toml file. Execute commands using mise exec or mise run to automatically load the specified tools and project environment variables.
    mise exec -- <command>
    mise run <task_name>
  11. Use tool stubs for portable runtime selection

    A tool stub is an executable file that records how to obtain and run a specific tool. By committing these stubs to a repository (e.g., in ./bin/py), you ensure that any user running the command uses the intended runtime and arguments.
  12. Migrate from asdf to mise

    mise is compatible with asdf. It can read .tool-versions files and supports legacy asdf plugins, allowing users to start with existing version declarations before migrating to mise.toml for advanced features like environment variables and tasks.