Emacs custom service
This commit is contained in:
parent
81757ca17e
commit
889ecc9a44
3 changed files with 17 additions and 7 deletions
|
|
@ -1,5 +1,6 @@
|
||||||
{
|
{
|
||||||
config,
|
config,
|
||||||
|
pkgs,
|
||||||
hwconfig,
|
hwconfig,
|
||||||
inputs,
|
inputs,
|
||||||
...
|
...
|
||||||
|
|
@ -10,4 +11,19 @@ in {
|
||||||
enable = true;
|
enable = true;
|
||||||
package = emacs;
|
package = emacs;
|
||||||
};
|
};
|
||||||
|
systemd.user.services.emacs = {
|
||||||
|
Unit = {
|
||||||
|
Description = "Launches (and relaunches) emacs";
|
||||||
|
};
|
||||||
|
Install = {
|
||||||
|
WantedBy = ["default.target"];
|
||||||
|
};
|
||||||
|
Service = {
|
||||||
|
ExecStart = "${pkgs.writeShellScript "run-emacs" ''
|
||||||
|
${emacs}/bin/emacs --fg-daemon
|
||||||
|
''}";
|
||||||
|
Restart = "on-failure";
|
||||||
|
RestartSec = 5;
|
||||||
|
};
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -115,12 +115,6 @@ in {
|
||||||
"${../../modules/hyprland/wallpaper.jpg}"
|
"${../../modules/hyprland/wallpaper.jpg}"
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
{
|
|
||||||
command = [
|
|
||||||
"${config.programs.emacs.package}/bin/emacs"
|
|
||||||
"--daemon"
|
|
||||||
];
|
|
||||||
}
|
|
||||||
];
|
];
|
||||||
layout = {
|
layout = {
|
||||||
preset-column-widths = [
|
preset-column-widths = [
|
||||||
|
|
|
||||||
|
|
@ -18,7 +18,7 @@ in {
|
||||||
#initialPassword = "1234";
|
#initialPassword = "1234";
|
||||||
hashedPasswordFile = config.sops.secrets."users/${username}".path;
|
hashedPasswordFile = config.sops.secrets."users/${username}".path;
|
||||||
packages = with pkgs; [];
|
packages = with pkgs; [];
|
||||||
linger = true;
|
linger = false;
|
||||||
|
|
||||||
openssh.authorizedKeys.keys = [
|
openssh.authorizedKeys.keys = [
|
||||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIGMt3PWVvmEL6a0HHTsxL4KMq1UGKFdzgX5iIkm6owGQ kylekrein@kylekrein-mac"
|
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIGMt3PWVvmEL6a0HHTsxL4KMq1UGKFdzgX5iIkm6owGQ kylekrein@kylekrein-mac"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue