mirror of
https://github.com/davegallant/nix-config
synced 2025-08-06 07:13:40 +00:00
Fix home-manager impurity and add brew configuration
This commit is contained in:
22
rebuild.sh
22
rebuild.sh
@@ -4,17 +4,17 @@ cd "$(dirname "$0")" || exit
|
||||
|
||||
uname="$(uname -s)"
|
||||
case "${uname}" in
|
||||
Linux*) machine=linux;;
|
||||
Darwin*) machine=mac;;
|
||||
*) machine="unknown"
|
||||
Linux*) machine=linux ;;
|
||||
Darwin*) machine=mac ;;
|
||||
*) machine="unknown" ;;
|
||||
esac
|
||||
|
||||
if [[ "$machine" == "linux" ]]; then
|
||||
exec nixos-rebuild -I nixos-config="machines/$(hostname)/configuration.nix" "$@" --flake '.#'
|
||||
elif [[ "$machine" == "mac" ]]; then
|
||||
exec darwin-rebuild "$@" --flake . --impure # TODO: What is causing this impurity?
|
||||
else
|
||||
echo 'Unsupported OS.'
|
||||
echo 'Exiting...'
|
||||
exit 1
|
||||
if [[ "$machine" == "linux" ]]; then
|
||||
exec nixos-rebuild -I nixos-config="machines/$(hostname)/configuration.nix" "$@" --flake '.#'
|
||||
elif [[ "$machine" == "mac" ]]; then
|
||||
exec darwin-rebuild "$@" --flake .
|
||||
else
|
||||
echo 'Unsupported OS.'
|
||||
echo 'Exiting...'
|
||||
exit 1
|
||||
fi
|
||||
|
Reference in New Issue
Block a user