fix salut timeout; move tray service to wayland; hack buggy systemd ordering

This commit is contained in:
steveej 2023-05-23 20:32:32 +02:00
parent e2abe10c28
commit 2c8f489f8b
5 changed files with 26 additions and 18 deletions

View file

@ -40,14 +40,6 @@ in {
home.sessionVariables.GOPATH = "$HOME/src/go"; home.sessionVariables.GOPATH = "$HOME/src/go";
home.sessionVariables.PATH = pkgs.lib.concatStringsSep ":" ["$HOME/.local/bin" "$PATH"]; home.sessionVariables.PATH = pkgs.lib.concatStringsSep ":" ["$HOME/.local/bin" "$PATH"];
# workaround: usually created by 'home.xsession.enabled=true' and i don't use with gnome
systemd.user.targets.tray = {
Unit = {
Description = "Home Manager System Tray";
Requires = ["graphical-session-pre.target"];
};
};
home.packages = home.packages =
[] []
++ (with pkgs; [ ++ (with pkgs; [

View file

@ -24,6 +24,8 @@ in {
# flameshot.enable = true; # flameshot.enable = true;
}; };
services.gpg-agent.pinentryFlavor = "gnome3";
home.packages = [ home.packages = [
pkgs.swayidle pkgs.swayidle
pkgs.swaylock pkgs.swaylock
@ -111,7 +113,7 @@ in {
"${modifier}+Control+Shift+Up" = "move workspace to output up"; "${modifier}+Control+Shift+Up" = "move workspace to output up";
"${modifier}+Control+Shift+Down" = "move workspace to output down"; "${modifier}+Control+Shift+Down" = "move workspace to output down";
"${modifier}+Shift+e" = "exec swaymsg exit"; "${modifier}+Shift+e" = "exec ${pkgs.sway}/bin/swaymsg exit";
"${modifier}+q" = "kill"; "${modifier}+q" = "kill";
"${modifier}+x" = "exec ${swapOutputWorkspaces}"; "${modifier}+x" = "exec ${swapOutputWorkspaces}";
@ -131,10 +133,13 @@ in {
terminal = "alacritty"; terminal = "alacritty";
startup = [ startup = [
# Launch Firefox on start {command = builtins.toString(pkgs.writeShellScript "ensure-graphical-session" ''
# {command = "firefox";} (
# {command = "gnome-keyring --replace"} ${pkgs.coreutils}/bin/sleep 0.2
{command = "systemctl --user restart waybar";} ${pkgs.systemd}/bin/systemctl --user restart graphical-session.target
) &
'');
}
]; ];
colors.focused = lib.mkOptionDefault { colors.focused = lib.mkOptionDefault {

View file

@ -25,6 +25,13 @@ in {
network-manager-applet.enable = true; network-manager-applet.enable = true;
}; };
systemd.user.targets.tray = {
Unit = {
Description = "Home Manager System Tray";
Requires = ["graphical-session-pre.target"];
};
};
home.packages = with pkgs; [ home.packages = with pkgs; [
# required by network-manager-applet # required by network-manager-applet
pkgs.networkmanagerapplet pkgs.networkmanagerapplet

View file

@ -1,7 +1,11 @@
{lib, pkgs, ...}: { {lib, pkgs, config, ...}: {
home.packages = [ home.packages = [
pkgs.gcr pkgs.gcr
]; ] ++
(if config.services.gpg-agent.pinentryFlavor == "gtk2" then [pkgs.pinentry-gtk2]
else if config.services.gpg-agent.pinentryFlavor == "gnome3" then [pkgs.pinentry-gnome]
else [])
;
programs.gpg.enable = true; programs.gpg.enable = true;
services.gpg-agent = { services.gpg-agent = {

View file

@ -20,15 +20,15 @@ in
enable = true; enable = true;
text = '' text = ''
[notifications] [notifications]
timeout = 5 timeout = 5000
[window] [window]
auto-hide = true auto-hide = true
anchor = bottom anchor = bottom-right
transition = slidebottom
[mode] [mode]
single = true single = true
do-not-disturb = false
[style] [style]
preference = dark preference = dark