From 944bced757bcdee10f5705e7c5c9f19c625bfe3b Mon Sep 17 00:00:00 2001 From: clerie Date: Mon, 28 Jul 2025 22:36:49 +0200 Subject: [PATCH 1/3] pkgs/pipewire-all-bluetooth: A pipewire audio sink that distributes to all Bluetooth speakers --- configuration/desktop/audio.nix | 3 ++ pkgs/overlay.nix | 1 + .../pipewire-all-bluetooth/all-bluetooth.conf | 29 +++++++++++++++++++ pkgs/pipewire-all-bluetooth/default.nix | 9 ++++++ 4 files changed, 42 insertions(+) create mode 100644 pkgs/pipewire-all-bluetooth/all-bluetooth.conf create mode 100644 pkgs/pipewire-all-bluetooth/default.nix diff --git a/configuration/desktop/audio.nix b/configuration/desktop/audio.nix index 19d70ac..f344089 100644 --- a/configuration/desktop/audio.nix +++ b/configuration/desktop/audio.nix @@ -14,6 +14,9 @@ pulse = { enable = true; }; + configPackages = [ + pkgs.pipewire-all-bluetooth + ]; }; environment.systemPackages = with pkgs; [ diff --git a/pkgs/overlay.nix b/pkgs/overlay.nix index 9874d11..5bb0aca 100644 --- a/pkgs/overlay.nix +++ b/pkgs/overlay.nix @@ -23,6 +23,7 @@ final: prev: { nixfiles-generate-config = final.callPackage ./nixfiles/nixfiles-generate-config.nix {}; nixfiles-generate-backup-secrets = final.callPackage ./nixfiles/nixfiles-generate-backup-secrets.nix {}; nixfiles-update-ssh-host-keys = final.callPackage ./nixfiles/nixfiles-update-ssh-host-keys.nix {}; + pipewire-all-bluetooth = final.callPackage ./pipewire-all-bluetooth {}; print-afra = final.callPackage ./print-afra {}; run-with-docker-group = final.callPackage ./run-with-docker-group {}; ssh-gpg = final.callPackage ./ssh-gpg {}; diff --git a/pkgs/pipewire-all-bluetooth/all-bluetooth.conf b/pkgs/pipewire-all-bluetooth/all-bluetooth.conf new file mode 100644 index 0000000..4a4e38d --- /dev/null +++ b/pkgs/pipewire-all-bluetooth/all-bluetooth.conf @@ -0,0 +1,29 @@ +context.modules = [ +{ name = libpipewire-module-combine-stream + args = { + combine.mode = sink + node.name = "all-bluetooth" + node.description = "All Bluetooth devices" + combine.latency-compensate = false + combine.props = { + audio.position = [ FL FR ] + } + stream.props = { + } + stream.rules = [ + { + matches = [ + { + node.name = "~bluez_output.*" + media.class = "Audio/Sink" + } + ] + actions = { + create-stream = { + } + } + } + ] + } +} +] diff --git a/pkgs/pipewire-all-bluetooth/default.nix b/pkgs/pipewire-all-bluetooth/default.nix new file mode 100644 index 0000000..abd0d69 --- /dev/null +++ b/pkgs/pipewire-all-bluetooth/default.nix @@ -0,0 +1,9 @@ +{ +runCommand, +... }: + +runCommand "pipewire-all-bluetooth" {} '' + mkdir -p $out/share/pipewire/pipewire.conf.d + + cp ${./all-bluetooth.conf} $out/share/pipewire/pipewire.conf.d/all-bluetooth.conf +'' From f5ec777e9b0107390e18ff390528e1bac8fcac7f Mon Sep 17 00:00:00 2001 From: clerie Date: Mon, 28 Jul 2025 22:48:59 +0200 Subject: [PATCH 2/3] flake/hydraJobs.nix: Track additional packages in hydra --- flake/hydraJobs.nix | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/flake/hydraJobs.nix b/flake/hydraJobs.nix index 017901b..9ebaeb3 100644 --- a/flake/hydraJobs.nix +++ b/flake/hydraJobs.nix @@ -10,6 +10,12 @@ let in { inherit (self) packages; + extraTrackedPackages = nixpkgs.lib.genAttrs [ "x86_64-linux" "aarch64-linux" ] (system: + nixpkgs.lib.genAttrs [ + "hydra" + "lix" + ] (name: self.nixpkgs."${system}"."${name}") + ); nixosConfigurations = buildHosts self.nixosConfigurations; iso = self.nixosConfigurations._iso.config.system.build.isoImage; } From 905682cf1735543a9bd35f733c62f7807e72a79d Mon Sep 17 00:00:00 2001 From: Flake Update Bot Date: Tue, 29 Jul 2025 03:04:11 +0200 Subject: [PATCH 3/3] Update nixpkgs 2025-07-29-01-03 --- flake.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/flake.lock b/flake.lock index 59fd0de..ee0c8ba 100644 --- a/flake.lock +++ b/flake.lock @@ -646,11 +646,11 @@ }, "nixpkgs_5": { "locked": { - "lastModified": 1750776420, - "narHash": "sha256-/CG+w0o0oJ5itVklOoLbdn2dGB0wbZVOoDm4np6w09A=", + "lastModified": 1753549186, + "narHash": "sha256-Znl7rzuxKg/Mdm6AhimcKynM7V3YeNDIcLjBuoBcmNs=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "30a61f056ac492e3b7cdcb69c1e6abdcf00e39cf", + "rev": "17f6bd177404d6d43017595c5264756764444ab8", "type": "github" }, "original": {