add gameaudio module: run-on-gameaudio wrapper in PATH
This commit is contained in:
@@ -13,6 +13,7 @@
|
|||||||
modules.sops
|
modules.sops
|
||||||
modules.flatpaks
|
modules.flatpaks
|
||||||
modules.gamemode
|
modules.gamemode
|
||||||
|
modules.gameaudio
|
||||||
modules.hyprland
|
modules.hyprland
|
||||||
modules.fish
|
modules.fish
|
||||||
modules.tuigreet
|
modules.tuigreet
|
||||||
|
|||||||
@@ -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 "$@"
|
||||||
|
'')
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user