Enable xserver so X11 forwarding works properly

Enable autoLogin with sddm/plasma

Move some environment variable definitions around
This commit is contained in:
Evie Litherland-Smith 2024-08-05 14:49:37 +01:00
parent 4c4e43845f
commit 14d8fba769
4 changed files with 18 additions and 17 deletions

View file

@ -113,7 +113,7 @@
package = pkgs.nixVersions.latest; package = pkgs.nixVersions.latest;
settings.trusted-users = [ username ]; settings.trusted-users = [ username ];
}; };
services.greetd.settings.initial_session.user = username; services.displayManager.autoLogin.user = username;
programs.${loginShell} = lib.mkIf (loginShell != "bash") { enable = true; }; programs.${loginShell} = lib.mkIf (loginShell != "bash") { enable = true; };
users.users.${username} = { users.users.${username} = {
shell = pkgs.${loginShell}; shell = pkgs.${loginShell};

View file

@ -1,18 +1,10 @@
{ { pkgs, ... }:
config,
lib,
pkgs,
...
}:
{ {
nixpkgs.config.chromium.commandLineArgs = "--enable-features=UseOzonePlatform --ozone-platform=wayland"; nixpkgs.config.chromium.commandLineArgs = "--enable-features=UseOzonePlatform --ozone-platform=wayland";
system.autoUpgrade.operation = "boot"; system.autoUpgrade.operation = "boot";
hardware.bluetooth.enable = true; hardware.bluetooth.enable = true;
environment = { environment = {
sessionVariables = { sessionVariables.NIXOS_OZONE_WL = "1";
NIXOS_OZONE_WL = "1";
QT_QPA_PLATFORM = lib.mkIf config.programs.sway.enable "wayland";
};
systemPackages = with pkgs; [ systemPackages = with pkgs; [
libsecret libsecret
libnotify libnotify
@ -55,7 +47,7 @@
}; };
}; };
xserver = { xserver = {
enable = false; enable = true;
xkb = { xkb = {
layout = "gb"; layout = "gb";
variant = ""; variant = "";

View file

@ -1,11 +1,17 @@
{ pkgs, ... }: { pkgs, ... }:
{ {
imports = [ ./default.nix ]; imports = [ ./default.nix ];
environment.plasma6.excludePackages = with pkgs.kdePackages; [ plasma-browser-integration ]; environment = {
plasma6.excludePackages = with pkgs.kdePackages; [ plasma-browser-integration ];
sessionVariables.QT_QPA_PLATFORM = "wayland";
};
services = { services = {
displayManager.sddm = { displayManager = {
enable = true; autoLogin.enable = true;
wayland.enable = true; sddm = {
enable = true;
wayland.enable = true;
};
}; };
desktopManager.plasma6 = { desktopManager.plasma6 = {
enable = true; enable = true;

View file

@ -2,7 +2,10 @@
{ {
imports = [ ./default.nix ]; imports = [ ./default.nix ];
environment = { environment = {
sessionVariables.GRIM_DEFAULT_DIR = "$HOME/Pictures/Grim"; sessionVariables = {
QT_QPA_PLATFORM = "wayland";
GRIM_DEFAULT_DIR = "$HOME/Pictures/Grim";
};
systemPackages = with pkgs; [ systemPackages = with pkgs; [
wtype wtype
wl-clipboard wl-clipboard