add gameaudio module: run-on-gameaudio wrapper in PATH

This commit is contained in:
2026-08-25 19:15:12 +01:00
parent 7462276d09
commit b23538ce84
2 changed files with 28 additions and 0 deletions
@@ -13,6 +13,7 @@
modules.sops
modules.flatpaks
modules.gamemode
modules.gameaudio
modules.hyprland
modules.fish
modules.tuigreet
+27
View File
@@ -0,0 +1,27 @@
{
modules,
...
}:
{
modules.gameaudio = {
homeManager =
{
pkgs,
...
}:
{
home.packages = [
# Launch a program with all of its audio routed to GameAudioSink.
# Usage: run-on-gameaudio <command> [args...]
(pkgs.writeShellScriptBin "run-on-gameaudio" ''
if [ "$#" -eq 0 ]; then
echo "usage: run-on-gameaudio <command> [args...]" >&2
exit 1
fi
export PIPEWIRE_PROPS="target.object=GameAudioSink"
exec "$@"
'')
];
};
};
}