add greetd

This commit is contained in:
Leonardo Eugênio 2022-07-16 14:24:09 -03:00
parent 59d3c75ade
commit 92fd4fc65b
2 changed files with 34 additions and 5 deletions

View file

@ -60,6 +60,35 @@ in
# services.xserver.displayManager.gdm.enable = true; # services.xserver.displayManager.gdm.enable = true;
# services.xserver.desktopManager.gnome.enable = true; # services.xserver.desktopManager.gnome.enable = true;
# services.xserver.displayManager.autologin.user = "lelgenio"; # services.xserver.displayManager.autologin.user = "lelgenio";
services.greetd = let
swayConfig = pkgs.writeText "greetd-sway-config" ''
# `-l` activates layer-shell mode. Notice that `swaymsg exit` will run after gtkgreet.
exec "${pkgs.greetd.gtkgreet}/bin/gtkgreet -l -c sway; swaymsg exit"
bindsym Mod4+shift+e exec swaynag \
-t warning \
-m 'What do you want to do?' \
-b 'Poweroff' 'systemctl poweroff' \
-b 'Reboot' 'systemctl reboot'
input "*" {
repeat_delay 200
repeat_rate 30
xkb_layout us(colemak)
xkb_numlock enabled
xkb_options lv3:lsgt_switch,grp:shifts_toggle
}
'';
in {
enable = true;
settings = {
initial_session = {
command = "${pkgs.sway}/bin/sway";
user = "lelgenio";
};
default_session = {
command = "${pkgs.sway}/bin/sway --config ${swayConfig}";
};
};
};
# Configure keymap in X11 # Configure keymap in X11
services.xserver = { services.xserver = {
layout = "us"; layout = "us";
@ -92,7 +121,7 @@ in
extraGroups = [ "networkmanager" "wheel" "docker"]; extraGroups = [ "networkmanager" "wheel" "docker"];
shell = pkgs.fish; shell = pkgs.fish;
}; };
services.getty.autologinUser = "lelgenio"; # services.getty.autologinUser = "lelgenio";
programs.fish.enable = true; programs.fish.enable = true;
services.syncthing = { services.syncthing = {
enable = true; enable = true;

View file

@ -99,11 +99,11 @@ in {
]; ];
programs.fish.enable = true; programs.fish.enable = true;
programs.helix = { programs.helix = {
enable = true; enable = true;
settings = { settings = {
theme = "gruvbox"; theme = "gruvbox";
};
}; };
};
programs.firefox = { programs.firefox = {
enable = true; enable = true;
package = pkgs.firefox; package = pkgs.firefox;