Update common.nix

This commit is contained in:
ediblerope 2025-12-04 12:30:15 +00:00 committed by GitHub
parent de4b6d86a8
commit 2ddf7ec35b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -26,10 +26,16 @@ networking.networkmanager.enable = true;
# Shell aliases
environment.shellAliases = {
# NEW Flake-based command
update = "sudo nixos-rebuild switch --flake .#FredOS-Gaming";
clean = "sudo nix-collect-garbage -d";
ll = "ls -alh";
update = ''
if ! nix-channel --list | grep -q "nixos.*nixos-unstable"; then
echo "Switching to nixos-unstable channel..."
sudo nix-channel --add https://nixos.org/channels/nixos-unstable nixos
sudo nix-channel --update
fi
sudo nixos-rebuild switch --upgrade --option tarball-ttl 0
'';
clean = "sudo nix-collect-garbage -d";
ll = "ls -alh";
};
# Add packages