aRustyDev / aRustyDev/dotfiles
Fix darwin-rebuild PATH configuration
- Vorherrschende Sprache
- Jupyter Notebook
- Sterne
- 1
- Forks
- 0
- PR-Merge-Kennzahlen
- Keine gemergten PRs in 30 T.
Beschreibung
## Summary
Resolved issue where `darwin-rebuild` command was not found after installation due to PATH configuration problems.
## Problem
- `/run/current-system/sw/bin` was not in user's PATH
- Nix-Darwin configurations were using `lib.mkForce` which prevented proper PATH merging
- User's .zshrc was not able to control final PATH ordering
## Solution
1. Removed all `lib.mkForce` usage from PATH configurations in:
- `cfs.nix`
- `personal.nix`
- `seneca.nix`
2. Updated `.zshrc` to properly configure PATH after nix-daemon.sh:
```bash
# Initialize path array from current PATH
path=(${(s/:/)PATH})
# Ensure darwin-rebuild is accessible
if [[ -d /run/current-system/sw/bin ]]; then
path=('/run/current-system/sw/bin' $path)
fi
```
## Key Learning
User shell configuration should have final control over PATH ordering. Nix should provide paths but not force ordering.
## Related
- This was discovered while working on MCP server module implementation
- Solution documented in `.claude/guides/lessons-learned-nix.md`
Beitragsleitfaden
Rechercherichtung
Überprüfe die PATH-Konfigurationen in cfs.nix, personal.nix und seneca.nix und untersuche anschließend die Änderungen an .zshrc im Zusammenhang mit nix-daemon.sh. Stelle sicher, dass /run/current-system/sw/bin in PATH erhalten bleibt und dass darwin-rebuild nach der Installation verfügbar ist.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- zsh
- Bereich
- devops
- Issue-Typ
- Bug
- Schwierigkeit
- 2/5
- Geschätzter Aufwand
- 1-3 Stunden
- Aktivitätsstatus
- Veraltet
- Klarheit
- Klar beschrieben
- Anfängerfreundlichkeit
- 35/100