Autostart sway when logins from tty

This commit is contained in:
Yorick Barbanneau 2023-10-01 16:59:23 +02:00
parent d0c32b3e70
commit b7b4f5d334
2 changed files with 8 additions and 0 deletions

View file

@ -9,6 +9,7 @@ in {
./swaylock.nix
./swayidle.nix
./fuzzel.nix
./zsh-autostart.nix
] ++ (
if hostConfig.laptop then
[ ./kanshi.nix ]

View file

@ -0,0 +1,7 @@
{
programs.zsh.loginExtra = ''
if [ "$(tty)" = "/dev/tty1" ]; then
exec sway &> /dev/null
fi
'';
}