aboutsummaryrefslogtreecommitdiff
path: root/modules/client/labwc/default.nix
blob: 6512e7d10b2146c1abe934dedeadb672ede2bcdf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
{ config, pkgs, ... }:
# Set up a complete labwc instance system-side
{
  imports = [
    ../thunar
    ../waybar
    ../xserver
  ];
  
  # Enable labwc
  programs.labwc.enable = true;

  # Enable XDG portals for wl-roots
  xdg.portal = {
    wlr.enable = true;
    extraPortals = with pkgs; [
      xdg-desktop-portal-gtk
    ];
    enable = true;
  };

  # Enable tuigreet
  services = {
    greetd = {
      enable = true;
      settings = {
        default_session = {
          command = "${pkgs.greetd.tuigreet}/bin/tuigreet --user-menu -rti --asterisks --cmd labwc";
          user = "greeter";
        };
      };
    };
  };

  # Hide stderror and bootlogs from filling tuigreet
  systemd.services.greetd.serviceConfig = {
    Type = "idle";
    StandardInput = "tty";
    StandardOutput = "ttu";
    StandardError = "journal"; # logs erros to journal, preventing spam on tuigreet

    TTYReset = true;
    TTYVHangup = true;
    TTYVTDisallocate = true;
  };
}
Directive (EU) 2019/790, Article 4(3); all rights regarding Text and Data Mining (TDM) are reserved.