From 1658f2d4cafaa6e100707db6ded53e5f07401461 Mon Sep 17 00:00:00 2001 From: Gabriel Arazas Date: Sun, 13 Nov 2022 05:57:09 +0800 Subject: [PATCH] services/bleachbit: cleanup and format --- modules/home-manager/services/bleachbit.nix | 44 +++++++++------------ 1 file changed, 19 insertions(+), 25 deletions(-) diff --git a/modules/home-manager/services/bleachbit.nix b/modules/home-manager/services/bleachbit.nix index df4bcfba..3d849764 100644 --- a/modules/home-manager/services/bleachbit.nix +++ b/modules/home-manager/services/bleachbit.nix @@ -104,35 +104,29 @@ in { }; config = lib.mkIf cfg.enable { - systemd.user = { - services = { - bleachbit-cleanup = { - Unit = { - Description = "Periodic cleaning with Bleachbit"; - Documentation = [ "man:bleachbit(1)" "https://www.bleachbit.org" ]; - }; - - Service.ExecStart = '' - ${cfg.package}/bin/bleachbit --clean ${lib.escapeShellArgs cleaners} - ''; - }; + systemd.user.services.bleachbit-cleanup = { + Unit = { + Description = "Periodic cleaning with Bleachbit"; + Documentation = [ "man:bleachbit(1)" "https://www.bleachbit.org" ]; }; - timers = { - bleachbit-cleanup = { - Unit = { - Description = "Periodic cleaning with Bleachbit"; - Documentation = [ "man:bleachbit(1)" "https://www.bleachbit.org" ]; - PartOf = [ "default.target" ]; - }; + Service.ExecStart = '' + ${cfg.package}/bin/bleachbit --clean ${lib.escapeShellArgs cleaners} + ''; + }; - Install.WantedBy = [ "timers.target" ]; + systemd.user.timers.bleachbit-cleanup = { + Unit = { + Description = "Periodic cleaning with Bleachbit"; + Documentation = [ "man:bleachbit(1)" "https://www.bleachbit.org" ]; + PartOf = [ "default.target" ]; + }; - Timer = { - OnCalendar = cfg.startAt; - Persistent = cfg.persistent; - }; - }; + Install.WantedBy = [ "timers.target" ]; + + Timer = { + OnCalendar = cfg.startAt; + Persistent = cfg.persistent; }; }; };