add nix-maintenance.sh

This commit is contained in:
Astro 2019-02-18 19:56:44 +01:00
parent 96e19766a7
commit 0c9ce308c2
1 changed files with 10 additions and 0 deletions

10
nix-maintenance.sh Executable file
View File

@ -0,0 +1,10 @@
#!/usr/bin/env bash
set -x
set -e
sudo nix-channel --update
time nix-env -- -u \*
time sudo nixos-rebuild switch
time sudo nix-collect-garbage -d
time sudo nix-store --optimise