chore(mise): update configs and add cleanup script documentation

Update tooling configs, shell settings, and editor configurations
as part of the mise migration. Add companion documentation for the
cleanup-old-version-managers script and remove unused fish completions.
This commit is contained in:
2026-03-18 08:43:32 +02:00
parent d5e692e997
commit df84f1dc0e
17 changed files with 82 additions and 35 deletions

View File

@@ -0,0 +1,20 @@
# cleanup-old-version-managers
Remove old version manager installations that have been replaced by mise.
## Usage
```bash
scripts/cleanup-old-version-managers.sh [--dry-run]
```
## What it does
1. Removes data directories for nvm, fnm, pyenv, goenv, and bob-nvim.
2. Removes cargo-installed tool binaries now managed by mise.
3. Removes go-installed tool binaries from `$GOPATH/bin`.
4. Uninstalls Homebrew packages replaced by mise (if brew is available).
Mason binaries (`$XDG_DATA_HOME/nvim/mason/`) are not touched.
Pass `--dry-run` to preview what would be removed without making changes.

View File

@@ -13,8 +13,8 @@ remove_dir()
{
local dir="$1"
local label="$2"
if [ -d "$dir" ]; then
if [ "$DRY_RUN" = "--dry-run" ]; then
if [[ -d "$dir" ]]; then
if [[ "$DRY_RUN" = "--dry-run" ]]; then
msgr warn "[DRY RUN] Would remove $label: $dir"
else
msgr run "Removing $label: $dir"
@@ -30,8 +30,8 @@ remove_file()
{
local file="$1"
local label="$2"
if [ -f "$file" ]; then
if [ "$DRY_RUN" = "--dry-run" ]; then
if [[ -f "$file" ]]; then
if [[ "$DRY_RUN" = "--dry-run" ]]; then
msgr warn "[DRY RUN] Would remove $label: $file"
else
rm -f "$file"
@@ -67,7 +67,7 @@ remove_dir "$XDG_DATA_HOME/bob" "bob-nvim data"
CARGO_BIN="${XDG_DATA_HOME}/cargo/bin"
CARGO_MANAGED_TOOLS=(
bkt bottom btm difft difftastic eza fd rg ripgrep
bkt btm difft eza fd rg
tree-sitter tmux-sessionizer zoxide bob
cargo-install-update cargo-cache
)
@@ -82,7 +82,7 @@ GO_BIN="${XDG_DATA_HOME}/go/bin"
GO_MANAGED_TOOLS=(
yamlfmt cheat glow fzf gum sesh git-profile
)
if [ "$GO_BIN" != "$XDG_BIN_HOME" ] && [ -d "$GO_BIN" ]; then
if [[ "$GO_BIN" != "$XDG_BIN_HOME" ]] && [[ -d "$GO_BIN" ]]; then
for tool in "${GO_MANAGED_TOOLS[@]}"; do
remove_file "$GO_BIN/$tool" "go-installed $tool"
done
@@ -108,11 +108,12 @@ if command -v brew &> /dev/null; then
)
for pkg in "${BREW_REMOVE[@]}"; do
if brew list "$pkg" &> /dev/null; then
if [ "$DRY_RUN" = "--dry-run" ]; then
if [[ "$DRY_RUN" = "--dry-run" ]]; then
msgr warn "[DRY RUN] Would brew uninstall $pkg"
else
msgr run "Uninstalling brew package: $pkg"
brew uninstall --ignore-dependencies "$pkg" || true
msgr warn "Note: $pkg may have dependents"
brew uninstall "$pkg" || true
msgr run_done "Uninstalled $pkg"
fi
fi

View File

@@ -10,7 +10,7 @@ scripts/install-python-packages.sh
## What it does
1. Checks that `uv` is available; if missing, installs it via the official installer.
1. Checks that `uv` is available; if missing, exits with an error (install `uv` via mise first).
2. Installs each library from the inline `libraries` array using `uv pip install --system --upgrade`.
To add or remove packages, edit the `libraries` array in `scripts/install-python-packages.sh`.