mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-15 22:36:23 +01:00
nixos/river: init module
This commit is contained in:
parent
c7bd5289d6
commit
8f421acbc5
5 changed files with 65 additions and 7 deletions
|
@ -10,6 +10,8 @@
|
|||
|
||||
<!-- To avoid merge conflicts, consider adding your item at an arbitrary place in the list instead. -->
|
||||
|
||||
- [river](https://github.com/riverwm/river), A dynamic tiling wayland compositor. Available as [programs.river](#opt-programs.river.enable).
|
||||
|
||||
## Backward Incompatibilities {#sec-release-23.11-incompatibilities}
|
||||
|
||||
- The latest version of `clonehero` now stores custom content in `~/.clonehero`. See the [migration instructions](https://clonehero.net/2022/11/29/v23-to-v1-migration-instructions.html). Typically, these content files would exist along side the binary, but the previous build used a wrapper script that would store them in `~/.config/unity3d/srylain Inc_/Clone Hero`.
|
||||
|
|
|
@ -255,6 +255,7 @@
|
|||
./programs/usbtop.nix
|
||||
./programs/vim.nix
|
||||
./programs/wavemon.nix
|
||||
./programs/wayland/river.nix
|
||||
./programs/wayland/sway.nix
|
||||
./programs/wayland/waybar.nix
|
||||
./programs/weylus.nix
|
||||
|
|
59
nixos/modules/programs/wayland/river.nix
Normal file
59
nixos/modules/programs/wayland/river.nix
Normal file
|
@ -0,0 +1,59 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
with lib; let
|
||||
cfg = config.programs.river;
|
||||
in {
|
||||
options.programs.river = {
|
||||
enable = mkEnableOption (lib.mdDoc "river, a dynamic tiling Wayland compositor");
|
||||
|
||||
package = mkOption {
|
||||
type = with types; nullOr package;
|
||||
default = pkgs.river;
|
||||
defaultText = literalExpression "pkgs.river";
|
||||
description = lib.mdDoc ''
|
||||
River package to use.
|
||||
Set to `null` to not add any River package to your path.
|
||||
This should be done if you want to use the Home Manager River module to install River.
|
||||
'';
|
||||
};
|
||||
|
||||
extraPackages = mkOption {
|
||||
type = with types; listOf package;
|
||||
default = with pkgs; [
|
||||
swaylock
|
||||
foot
|
||||
dmenu
|
||||
];
|
||||
defaultText = literalExpression ''
|
||||
with pkgs; [ swaylock foot dmenu ];
|
||||
'';
|
||||
example = literalExpression ''
|
||||
with pkgs; [
|
||||
termite rofi light
|
||||
]
|
||||
'';
|
||||
description = lib.mdDoc ''
|
||||
Extra packages to be installed system wide. See
|
||||
[Common X11 apps used on i3 with Wayland alternatives](https://github.com/swaywm/sway/wiki/i3-Migration-Guide#common-x11-apps-used-on-i3-with-wayland-alternatives)
|
||||
for a list of useful software.
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
config =
|
||||
mkIf cfg.enable (mkMerge [
|
||||
{
|
||||
environment.systemPackages = optional (cfg.package != null) cfg.package ++ cfg.extraPackages;
|
||||
|
||||
# To make a river session available if a display manager like SDDM is enabled:
|
||||
programs.xwayland.enable = mkDefault true;
|
||||
}
|
||||
(import ./wayland-session.nix { inherit lib pkgs; })
|
||||
]);
|
||||
|
||||
meta.maintainers = with lib.maintainers; [ GaetanLepage ];
|
||||
}
|
|
@ -150,9 +150,8 @@ in {
|
|||
};
|
||||
};
|
||||
# To make a Sway session available if a display manager like SDDM is enabled:
|
||||
services.xserver.displayManager.sessionPackages = optionals (cfg.package != null) [ cfg.package ];
|
||||
}
|
||||
(import ./wayland-session.nix { inherit lib; })
|
||||
services.xserver.displayManager.sessionPackages = optionals (cfg.package != null) [ cfg.package ]; }
|
||||
(import ./wayland-session.nix { inherit lib pkgs; })
|
||||
]);
|
||||
|
||||
meta.maintainers = with lib.maintainers; [ primeos colemickens ];
|
||||
|
|
|
@ -1,12 +1,10 @@
|
|||
{ lib, ... }: with lib; {
|
||||
|
||||
{ lib, pkgs, ... }: with lib; {
|
||||
security = {
|
||||
polkit.enable = true;
|
||||
pam.services.swaylock = {};
|
||||
};
|
||||
|
||||
hardware.opengl.enable = mkDefault true;
|
||||
|
||||
fonts.enableDefaultFonts = mkDefault true;
|
||||
|
||||
programs = {
|
||||
|
@ -14,7 +12,6 @@
|
|||
xwayland.enable = mkDefault true;
|
||||
};
|
||||
|
||||
|
||||
xdg.portal = {
|
||||
enable = mkDefault true;
|
||||
|
||||
|
|
Loading…
Reference in a new issue