Skip to content

refactor(setup): let mise create ~/.config/mise instead of ln - #89

Merged
djgoku merged 1 commit into
mainfrom
fix/dotfiles-bootstrap-order
Aug 23, 2026
Merged

refactor(setup): let mise create ~/.config/mise instead of ln#89
djgoku merged 1 commit into
mainfrom
fix/dotfiles-bootstrap-order

Conversation

@djgoku

@djgoku djgoku commented Aug 23, 2026

Copy link
Copy Markdown
Owner

~/.config/mise is declared in [dotfiles], so hand-rolling it with ln duplicated a managed path -- the same smell already removed for ~/.dot-files. It was not actually unavoidable: MISE_CONFIG_DIR points mise straight at the config inside the clone, and mise then creates both symlinks from its own entries.

The result is also more correct. mise writes
~/.config/mise -> ~/.dot-files/config/mise, honouring dotfiles.root, where the hand-rolled link pointed at the repo path and bypassed it.

Applied one target per invocation, in order: mise validates the sources of every target named in a single call, so naming both at once fails on ~/.config/mise's source living under ~/.dot-files, which does not exist yet. MISE_CONFIG_DIR is unset afterwards so the rest of the run reads config through the symlink, exactly as a normal invocation does.

Note MISE_GLOBAL_CONFIG_FILE is not a substitute: it swaps only config.toml and still loads ~/.config/mise/conf.d/*. MISE_CONFIG_DIR redirects the whole directory, conf.d included.

setup.sh is now down to two genuinely imperative steps: clone, and install mise. Verified end to end against a HOME with no .config directory at all.

~/.config/mise is declared in [dotfiles], so hand-rolling it with `ln`
duplicated a managed path -- the same smell already removed for ~/.dot-files.
It was not actually unavoidable: MISE_CONFIG_DIR points mise straight at the
config inside the clone, and mise then creates both symlinks from its own
entries.

The result is also more correct. mise writes
~/.config/mise -> ~/.dot-files/config/mise, honouring dotfiles.root, where the
hand-rolled link pointed at the repo path and bypassed it.

Applied one target per invocation, in order: mise validates the sources of
every target named in a single call, so naming both at once fails on
~/.config/mise's source living under ~/.dot-files, which does not exist yet.
MISE_CONFIG_DIR is unset afterwards so the rest of the run reads config
through the symlink, exactly as a normal invocation does.

Note MISE_GLOBAL_CONFIG_FILE is not a substitute: it swaps only config.toml
and still loads ~/.config/mise/conf.d/*. MISE_CONFIG_DIR redirects the whole
directory, conf.d included.

setup.sh is now down to two genuinely imperative steps: clone, and install
mise. Verified end to end against a HOME with no .config directory at all.
@djgoku
djgoku merged commit c18686b into main Aug 23, 2026
2 checks passed
@djgoku
djgoku deleted the fix/dotfiles-bootstrap-order branch August 23, 2026 02:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant