Merge remote-tracking branch 'origin/main'

This commit is contained in:
Lap Tran committed 2026-11-06 21:10:59 -05:00
commit e427a4079c
3 files changed
+44 -17

No files matched your search

+27 -1
View File
@@ -1,7 +1,8 @@
#!/usr/bin/env bash
# Rebuild nix-darwin + home-manager. Rotates stale home-manager *.backup files
# so a second switch never fails with "would be clobbered".
# Also upgrades grok-build and installs OpenCode 1.x (stable CLI for free-tier).
# Also updates flake inputs, upgrades grok-build, installs OpenCode 1.x
# (stable CLI for free-tier), and updates no-mistakes.
set -euo pipefail
DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd -P)"
ln -sfn "$DIR" ~/.dotfiles
@@ -31,6 +32,24 @@ else
echo "==> OpenCode 1.x already installed: $(${OPENCODE_BIN} --version)"
fi
echo "==> Updating no-mistakes..."
NO_MISTAKES_BIN="$HOME/.no-mistakes/bin/no-mistakes"
if [ -x "$NO_MISTAKES_BIN" ]; then
if "$NO_MISTAKES_BIN" update 2>&1; then
echo "==> no-mistakes update complete"
else
echo "==> WARNING: no-mistakes update failed. Skipping."
fi
elif command -v no-mistakes >/dev/null 2>&1; then
if no-mistakes update 2>&1; then
echo "==> no-mistakes update complete"
else
echo "==> WARNING: no-mistakes update failed. Skipping."
fi
else
echo "==> WARNING: no-mistakes not found. Skipping update."
fi
stamp="$(date +%Y%m%d-%H%M%S)"
# Paths home-manager manages via home.file (regular files become out-of-store symlinks).
managed=(
@@ -75,4 +94,11 @@ do
fi
done
echo "==> Updating flake inputs..."
if nix flake update --flake ~/.dotfiles 2>&1; then
echo "==> flake update complete"
else
echo "==> WARNING: flake update failed. Continuing with locked inputs."
fi
exec sudo darwin-rebuild switch --flake ~/.dotfiles#lt-mbp