about summary refs log tree commit diff
path: root/hosts/common/desktop
diff options
context:
space:
mode:
authorFranck Cuny <franck@fcuny.net>2022-04-05 16:47:35 -0700
committerFranck Cuny <franck@fcuny.net>2022-04-05 16:47:35 -0700
commit608deed2aaa88f88cb9230b9132294581b63bbab (patch)
tree702df49d0581bdfe2da66ccac315c9b262dca1de /hosts/common/desktop
parentwaybar: fix colors for the workspaces (diff)
downloadworld-608deed2aaa88f88cb9230b9132294581b63bbab.tar.gz
sound: add a new module
This is the start of yet another refactoring of the configuration.

Sound configuration is moving to a module, and we enable it as needed at
the host level. It takes care of configuring pipewire and install the
packages needed too.

This module is applied to the laptop and the desktop.
Diffstat (limited to '')
-rw-r--r--hosts/common/desktop/default.nix9
-rw-r--r--hosts/common/desktop/sound.nix22
2 files changed, 2 insertions, 29 deletions
diff --git a/hosts/common/desktop/default.nix b/hosts/common/desktop/default.nix
index b5effa9..6a752b6 100644
--- a/hosts/common/desktop/default.nix
+++ b/hosts/common/desktop/default.nix
@@ -1,10 +1,5 @@
-{lib, config, pkgs, ...}:
-{
-  imports = [
-    ./fonts.nix
-    ./sound.nix
-    ./xserver.nix
-  ];
+{ lib, config, pkgs, ... }: {
+  imports = [ ./fonts.nix ./xserver.nix ];
 
   services.avahi.enable = true;
   # Important to resolve .local domains of printers, otherwise you get an error
diff --git a/hosts/common/desktop/sound.nix b/hosts/common/desktop/sound.nix
deleted file mode 100644
index c72875d..0000000
--- a/hosts/common/desktop/sound.nix
+++ /dev/null
@@ -1,22 +0,0 @@
-{pkgs, config, lib, ...}:
-
-{
-  sound.enable = true;
-
-  security = { rtkit.enable = true; };
-
-  environment.systemPackages = with pkgs; [
-    # We install it to get access to pactl. It isn't enabled or run as a service.
-    pulseaudio
-  ];
-
-  services.pipewire = {
-    enable = true;
-    # Compatibility shims, adjust according to your needs
-    alsa.enable = true;
-    alsa.support32Bit = true;
-    pulse.enable = true;
-    jack.enable = true;
-  };
-  hardware.pulseaudio.enable = false;
-}