Rebuilt nixes
This commit is contained in:
+303
-304
File diff suppressed because it is too large
Load Diff
+13
-14
@@ -1457,22 +1457,21 @@ The configuration is done in the home manager section.
|
|||||||
|
|
||||||
** Setting the config
|
** Setting the config
|
||||||
#+begin_src nix :tangle configuration/end_script.nix :noweb tangle :mkdirp yes
|
#+begin_src nix :tangle configuration/end_script.nix :noweb tangle :mkdirp yes
|
||||||
{ config, pkgs, flakeRoot, lib, ... }:
|
systemd.user.services.endScript = lib.mkIf scriptExists {
|
||||||
let
|
|
||||||
scriptPath = flakeRoot + "/assets/scripts/end_script.sh";
|
|
||||||
scriptExists = builtins.pathExists scriptPath;
|
|
||||||
in
|
|
||||||
{
|
|
||||||
systemd.user.services.endScript = lib.mkIf scriptExists {
|
|
||||||
description = "Run end script after Home Manager";
|
description = "Run end script after Home Manager";
|
||||||
wantedBy = [ "default.target" ]; # Enable the service
|
wantedBy = [ ]; # Not needed for user services
|
||||||
after = [ "home-manager-activate.service" ];
|
after = [
|
||||||
serviceConfig.Type = "oneshot";
|
"home-manager-activate.service"
|
||||||
script = ''
|
"graphical-session.target" # If using a graphical session
|
||||||
${scriptPath}
|
];
|
||||||
'';
|
wantedBy = [ "default.target" ]; # This is redundant for user services
|
||||||
|
serviceConfig = {
|
||||||
|
Type = "oneshot";
|
||||||
|
RemainAfterExit = yes;
|
||||||
|
ExecStart = "${scriptPath}";
|
||||||
};
|
};
|
||||||
}
|
};
|
||||||
|
|
||||||
|
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
|
|||||||
Regular → Executable
@@ -1,7 +0,0 @@
|
|||||||
#!/usr/bin/env bash
|
|
||||||
set -euo pipefail
|
|
||||||
|
|
||||||
rm -f ~/.config/starship.toml.backup \
|
|
||||||
~/.config/waybar/style.css.backup \
|
|
||||||
~/.config/kitty/kitty.conf.backup \
|
|
||||||
~/.config/hypr/hyprland.conf.backup
|
|
||||||
@@ -1,16 +1,14 @@
|
|||||||
{ config, pkgs, flakeRoot, lib, ... }:
|
systemd.user.services.endScript = lib.mkIf scriptExists {
|
||||||
let
|
|
||||||
scriptPath = flakeRoot + "/assets/scripts/end_script.sh";
|
|
||||||
scriptExists = builtins.pathExists scriptPath;
|
|
||||||
in
|
|
||||||
{
|
|
||||||
systemd.user.services.endScript = lib.mkIf scriptExists {
|
|
||||||
description = "Run end script after Home Manager";
|
description = "Run end script after Home Manager";
|
||||||
wantedBy = [ "default.target" ]; # Enable the service
|
wantedBy = [ ]; # Not needed for user services
|
||||||
after = [ "home-manager-activate.service" ];
|
after = [
|
||||||
serviceConfig.Type = "oneshot";
|
"home-manager-activate.service"
|
||||||
script = ''
|
"graphical-session.target" # If using a graphical session
|
||||||
${scriptPath}
|
];
|
||||||
'';
|
wantedBy = [ "default.target" ]; # This is redundant for user services
|
||||||
|
serviceConfig = {
|
||||||
|
Type = "oneshot";
|
||||||
|
RemainAfterExit = yes;
|
||||||
|
ExecStart = "${scriptPath}";
|
||||||
};
|
};
|
||||||
}
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user