Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nixos/plasma: use upstream xsession/wayland files #100057

Merged
merged 5 commits into from
Oct 15, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions nixos/doc/manual/release-notes/rl-2111.section.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ In addition to numerous new and upgraded packages, this release has the followin
This allows activation scripts to output what they would change if the activation was really run.
The users/modules activation script supports this and outputs some of is actions.

- KDE Plasma now finally works on Wayland.
pasqui23 marked this conversation as resolved.
Show resolved Hide resolved

- bash now defaults to major version 5.

- Systemd was updated to version 249 (from 247).
Expand Down Expand Up @@ -338,6 +340,7 @@ In addition to numerous new and upgraded packages, this release has the followin
configuration file. For details, see the [upstream changelog](https://github.com/DataDog/datadog-agent/blob/main/CHANGELOG.rst).

- `opencv2` no longer includes the non-free libraries by default, and consequently `pfstools` no longer includes OpenCV support by default. Both packages now support an `enableUnfree` option to re-enable this functionality.
- `services.xserver.displayManager.defaultSession = "plasma5"` does not work anymore, instead use either `"plasma"` for the Plasma X11 session or `"plasmawayland"` for the Plasma Wayland sesison.

## Other Notable Changes {#sec-release-21.11-notable-changes}

Expand Down
12 changes: 3 additions & 9 deletions nixos/modules/services/x11/desktop-managers/plasma5.nix
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ let

pulseaudio = config.hardware.pulseaudio;
pactl = "${getBin pulseaudio.package}/bin/pactl";
startplasma-x11 = "${getBin plasma5.plasma-workspace}/bin/startplasma-x11";
sed = "${getBin pkgs.gnused}/bin/sed";

gtkrc2 = writeText "gtkrc-2.0" ''
Expand Down Expand Up @@ -136,9 +135,6 @@ let
fi
fi

''
+ ''
exec "${startplasma-x11}"
pasqui23 marked this conversation as resolved.
Show resolved Hide resolved
'';

in
Expand Down Expand Up @@ -183,18 +179,15 @@ in

config = mkMerge [
(mkIf cfg.enable {

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please revert.

# Seed our configuration into nixos-generate-config
system.nixos-generate-config.desktopConfiguration = [''
# Enable the Plasma 5 Desktop Environment.
services.xserver.displayManager.sddm.enable = true;
services.xserver.desktopManager.plasma5.enable = true;
''];

services.xserver.desktopManager.session = singleton {
name = "plasma5";
bgSupport = true;
start = startplasma;
pasqui23 marked this conversation as resolved.
Show resolved Hide resolved
};
services.xserver.displayManager.sessionPackages = [ pkgs.libsForQt5.plasma5.plasma-workspace ];
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
services.xserver.displayManager.sessionPackages = [ pkgs.libsForQt5.plasma5.plasma-workspace ];
services.xserver.displayManager.sessionPackages = [ pkgs.libsForQt5.plasma-workspace ];

We don't want to use aliases.


security.wrappers = {
kcheckpass =
Expand Down Expand Up @@ -389,6 +382,7 @@ in

# Update the start menu for each user that is currently logged in
system.userActivationScripts.plasmaSetup = activationScript;
services.xserver.displayManager.setupCommands = startplasma;
pasqui23 marked this conversation as resolved.
Show resolved Hide resolved

nixpkgs.config.firefox.enablePlasmaBrowserIntegration = true;
})
Expand Down
2 changes: 1 addition & 1 deletion nixos/tests/plasma5.nix
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import ./make-test-python.nix ({ pkgs, ...} :
imports = [ ./common/user-account.nix ];
services.xserver.enable = true;
services.xserver.displayManager.sddm.enable = true;
services.xserver.displayManager.defaultSession = "plasma5";
services.xserver.displayManager.defaultSession = "plasma";
services.xserver.desktopManager.plasma5.enable = true;
services.xserver.displayManager.autoLogin = {
enable = true;
Expand Down
1 change: 1 addition & 0 deletions pkgs/desktops/plasma-5/plasma-workspace/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ let inherit (lib) getBin getLib; in

mkDerivation {
name = "plasma-workspace";
passthru.providedSessions = [ "plasma" "plasmawayland" ];

nativeBuildInputs = [ extra-cmake-modules kdoctools ];
buildInputs = [
Expand Down