Configure and operate Mise for deterministic developer environments. Use when installing runtime/tool versions, defining reusable tasks, managing layered environment variables, migrating from asdf/nvm/pyenv, or debugging mise.toml behavior in CI and local shells. Keywords: mise, mise.toml, tool versions, tasks, env, asdf migration, setup automation, dev environment.
Overall
score
99%
Does it follow best practices?
Validation for skill structure
# Run a single task
mise run build
# Run with short alias
mise r build
# List all available tasks
mise tasks ls
mise tasksDependencies run automatically before the main task:
[tasks.deploy]
run = "./deploy.sh"
depends = ["build", "test"]# Running 'deploy' will automatically run 'build' and 'test' first
mise run deploySequential (default for array of commands):
[tasks.ci]
run = [
"mise run lint", # Runs first
"mise run test", # Runs second
"mise run build" # Runs third
]Parallel (for independent dependencies):
[tasks.ci]
depends = ["lint", "test"] # Run in parallel
run = "mise run build"# Pass arguments after --
mise run test -- --verbose --coverage
# Multiple arguments
mise run deploy -- --env production --region us-east-1Watch files and re-run tasks on changes:
# Watch and re-run on file changes
mise watch build
# Watch specific files
mise watch -g "src/**/*.ts" buildConfiguration:
[tasks.dev]
run = "npm run dev"
sources = ["src/**/*.ts", "src/**/*.tsx"]
outputs = ["dist/**/*"]Define shortcuts for common tasks:
[tasks.test]
alias = "t"
[tasks.deploy-production]
alias = ["deploy:prod", "dp"]mise run t # Runs test
mise run deploy:prod # Runs deploy-production[tasks.test]
run = "pytest"
env = { PYTEST_ARGS = "--verbose", DEBUG = "true" }[tasks.deploy]
run = "echo Deploying from {{ config_root }}"Built-in variables:
{{ config_root }}: Directory containing mise.toml{{ cwd }}: Current working directory# Root mise.toml
[tasks.build-all]
run = "mise run -C packages/api build && mise run -C packages/web build"
# Or use a script
[tasks.build-all]
run = '''
for pkg in packages/*; do
mise run -C "$pkg" build
done
'''# Run task in specific package
mise run -C packages/api test
# Run task in all packages
for pkg in packages/*; do
mise run -C "$pkg" lint
done# Save output to file
mise run build > build.log 2>&1
# Pipe to other commands
mise run test | grep FAILED[tasks.check]
run = "curl -sf https://api.example.com/health"Tasks return the exit code of the last command:
[tasks.ci]
run = [
"mise run lint", # If this fails, task stops
"mise run test",
"mise run build"
]#!/usr/bin/env bash
# mise description="Cleanup (ignore errors)"
rm -rf dist || true
rm -rf coverage || true#!/usr/bin/env bash
set -e # Exit on error
mise run test && mise run deploy || echo "Deployment cancelled"mise tasks ls to verify task registration--dry-run flags for destructive tasks#!/usr/bin/env bash
# mise description="Run tests"
if [ -t 0 ]; then
# Interactive mode
pytest --verbose
else
# CI mode
pytest --quiet --junit-xml=results.xml
fi#!/usr/bin/env bash
# mise description="Deploy with retry"
max_attempts=3
attempt=1
while [ $attempt -le $max_attempts ]; do
if ./deploy.sh; then
exit 0
fi
echo "Attempt $attempt failed, retrying..."
((attempt++))
sleep 5
done
exit 1#!/usr/bin/env bash
# mise description="Multi-step build"
echo "Step 1/3: Linting..."
mise run lint
echo "Step 2/3: Testing..."
mise run test
echo "Step 3/3: Building..."
mise run build
echo "✓ Build complete"