Display changed derivations on activation

This commit is contained in:
Geoffrey Frogeye 2024-04-01 14:59:07 +02:00
parent c319ee1394
commit 044318babc
Signed by: geoffrey
GPG key ID: C72403E7F82E6AD8
3 changed files with 16 additions and 0 deletions

View file

@ -2,6 +2,7 @@
{
config = {
home.packages = with pkgs; [
nvd
nix-diff
nix-tree
nix-output-monitor

View file

@ -8,6 +8,7 @@
./ccc
./common.nix
./desktop.nix
./diff
./gaming
./geoffrey.nix
./printing

14
os/diff/default.nix Normal file
View file

@ -0,0 +1,14 @@
{ pkgs, lib, config, ... }:
{
config = {
system.activationScripts.diff = {
supportsDryActivation = true;
text = ''
if [ -h /run/current-system ]
then
${pkgs.nvd}/bin/nvd --nix-bin-dir=${pkgs.nix}/bin diff /run/current-system "$systemConfig"
fi
'';
};
};
}