inputs: { config, lib, pkgs, ... }: with lib; let cfg = config.ezpc; in { imports = [inputs.niri.nixosModules.niri]; options.ezpc.enable = mkEnableOption "Enable ezpc system stuff"; config = mkIf cfg.enable { programs.niri = { enable = true; package = pkgs.niri-unstable; }; niri-flake.cache.enable = false; services.gnome.gnome-keyring.enable = lib.mkForce false; # xdg.portal = { # config.niri = { # default = [ "gnome" "gtk" ]; # # "org.freedesktop.impl.portal.Access" = "gtk"; # # "org.freedesktop.impl.portal.Notification" = "gtk"; # # "org.freedesktop.impl.portal.Secret" = "gnome-keyring"; # # "org.freedesktop.impl.portal.FileChooser" = "gtk"; # }; # extraPortals = [ pkgs.xdg-desktop-portal-gtk ]; # }; environment.sessionVariables = { QT_QPA_PLATFORM = "wayland;xcb"; MOZ_ENABLE_WAYLAND = "1"; QT_WAYLAND_DISABLE_WINDOWDECORATION = "1"; ECORE_EVAS_ENGINE = "wayland_egl"; ELM_ENGINE = "wayland_egl"; _JAVA_AWT_WM_NONREPARENTING = "1"; NIXOS_OZONE_WL = "1"; SDL_VIDEODRIVER = "wayland"; CLUTTER_BACKEND = "wayland"; }; services.greetd = { enable = lib.mkDefault true; settings = { default_session = { command = lib.mkDefault "${pkgs.tuigreet}/bin/tuigreet --time --user-menu --user-menu-max-uid 30000 --cmd niri-session"; }; }; }; i18n.inputMethod = { type = lib.mkDefault "ibus"; enable = lib.mkDefault true; ibus.engines = with pkgs.ibus-engines; [typing-booster uniemoji]; }; }; }