|
| 1 | +# mise.toml |
| 2 | +# Universal Toolchain Standard - Nov 2025 |
| 3 | +# Context: Solo Developer / 50+ Repos |
| 4 | + |
| 5 | +min_version = "2024.11.1" |
| 6 | + |
| 7 | +[tools] |
| 8 | +# --- Core Runtimes --- |
| 9 | +# Pinned to latest stable versions as of Nov 2025 |
| 10 | +node = "22" # LTS |
| 11 | +python = "3.13" # Stable (Performance Improvements) |
| 12 | +rust = "stable" # Latest Stable |
| 13 | +# go = "1.23" # Not currently used in ColdVox |
| 14 | + |
| 15 | +# --- Utility Toolchain --- |
| 16 | +# High-performance replacements for legacy tools |
| 17 | +uv = "latest" # Replaces pip/poetry (Rust-based) |
| 18 | +ripgrep = "latest" # Fast search |
| 19 | +jq = "latest" # JSON processor |
| 20 | +actionlint = "latest" # GitHub Actions linter |
| 21 | +typos = "latest" # Source code spell checker |
| 22 | + |
| 23 | +[env] |
| 24 | +# --- Environment Consistency --- |
| 25 | +# Prioritize local node_modules binaries. |
| 26 | +# This allows running 'eslint' directly without 'npx', saving network/startup time. |
| 27 | +_.path = ["{{config_root}}/node_modules/.bin"] |
| 28 | +PYTHONIOENCODING = "utf-8" |
| 29 | + |
| 30 | +[tasks.pre-commit] |
| 31 | +description = "Universal Git Pre-commit Hook" |
| 32 | +# CRITICAL: Invokes the local lint-staged binary directly via mise exec. |
| 33 | +# Avoids 'npx' to prevent registry lookup latency. |
| 34 | +run = "lint-staged" |
| 35 | + |
| 36 | +# --- TASK DELEGATION LAYER --- |
| 37 | +# lint-staged delegates logic here. |
| 38 | + |
| 39 | +[tasks."fmt:rust"] |
| 40 | +description = "Format & Lint Rust (Cargo)" |
| 41 | +run = """ |
| 42 | +cargo fmt -- |
| 43 | +# --allow-dirty is required because hooks run on dirty states by definition |
| 44 | +cargo clippy --fix --allow-dirty --allow-staged --all-targets --locked -- -D warnings |
| 45 | +""" |
| 46 | + |
| 47 | +[tasks."check:lockfiles"] |
| 48 | +description = "Prevent Lockfile Drift" |
| 49 | +# Runs a dry-run install to verify lockfiles match manifests. |
| 50 | +run = """ |
| 51 | +#!/bin/bash |
| 52 | +if [ -f package-lock.json ]; then npm ci --dry-run; fi |
| 53 | +""" |
| 54 | + |
| 55 | +[tasks.actionlint] |
| 56 | +description = "Lint GitHub Actions" |
| 57 | +run = "actionlint" |
| 58 | + |
| 59 | +[tasks.typos] |
| 60 | +description = "Spell Check" |
| 61 | +run = "typos" |
0 commit comments