setup astroid for autostart

This commit is contained in:
Leonardo Eugênio 2023-01-24 23:32:07 -03:00
parent 15bbc5a000
commit 4a53c981ae
2 changed files with 15 additions and 1 deletions

View file

@ -1,6 +1,19 @@
{ config, pkgs, lib, inputs, ... }: {
systemd.user.services = {
thunderbird = {
astroid = lib.mkIf (pkgs.uservars.email-client == "astroid") {
Unit = {
Description = "Astroid Email client";
PartOf = [ "graphical-session.target" ];
After = [ "graphical-session.target" ];
};
Service = {
ExecStartPre = "/usr/bin/env sleep 10s";
ExecStart = "${pkgs.astroid}/bin/astroid";
Restart = "on-failure";
};
Install = { WantedBy = [ "sway-session.target" ]; };
};
thunderbird = lib.mkIf (pkgs.uservars.email-client == "thunderbird") {
Unit = {
Description = "Thunderbird Email client";
PartOf = [ "graphical-session.target" ];

View file

@ -132,4 +132,5 @@ rec {
desktop = "sway";
browser = "qutebrowser";
editor = "kakoune";
email-client = "astroid";
}