Compare commits

..

6 Commits

Author SHA1 Message Date
58171c4860 chore: state after home update 2026-04-29 17:28:10 +02:00
bab565c6b2 chore: state before home update 2026-04-29 17:26:05 +02:00
8c364ddf66 chore: state after home update 2026-04-29 17:24:29 +02:00
d1aaf86410 chore: state before home update 2026-04-29 17:21:28 +02:00
7f560cdce2 chore: state before home update 2026-04-29 17:18:29 +02:00
26c9f700ec chore: state before home update 2026-04-29 17:08:18 +02:00
2 changed files with 52 additions and 0 deletions

View File

@@ -42,6 +42,7 @@
./modules/cli/git.nix
./modules/cli/fastfetch.nix
./modules/cli/kdeconnect.nix
./modules/cli/topgrade.nix
# gui tools
./modules/gui/kitty.nix
./modules/gui/satty.nix

51
modules/cli/topgrade.nix Normal file
View File

@@ -0,0 +1,51 @@
{ ... }:
let
system_path = "/etc/nixos";
home_path = "~/.config/home-manager/";
in
{
programs.topgrade = {
enable = true;
settings = {
misc = {
assume_yes = true;
pre_sudo = true;
disable = [
"flutter"
"node"
"hyprpm"
];
cleanup = true;
};
git = {
repos = [ "$XDG_PROJECTS_DIR/*" ];
};
pre_commands = {
"Git commit before system flake update" =
"cd ${system_path} && git add -A && git commit --allow-empty -m 'chore: state before system update'";
"Git commit before home flake update" =
"cd ${home_path} && git add -A && git commit --allow-empty -m 'chore: state before home update'";
"Git pull before system flake update " = "cd ${system_path} && git pull";
"Git pull before home flake update " = "cd ${home_path} && git pull";
};
commands = {
"Update system flake" = "cd ${system_path} && nix flake update";
"Update home flake" = "cd ${home_path} && nix flake update";
};
post_commands = {
"Git commit after system flake update" =
"cd ${system_path} && git add -A && git commit --allow-empty -m 'chore: state after system update'";
"Git commit after home flake update" =
"cd ${home_path} && git add -A && git commit --allow-empty -m 'chore: state after home update'";
"Git push system configuration" = "cd ${system_path} && git push";
"Git push home configuration" = "cd ${home_path} && git push";
};
};
};
}