1
0
mirror of https://github.com/kmein/niveum synced 2026-03-16 10:11:08 +01:00
Files
niveum/systems/zaatar/gaslight.nix

24 lines
661 B
Nix
Raw Normal View History

2022-03-10 21:52:12 +01:00
{pkgs, ...}: {
2020-09-14 08:33:39 +02:00
environment.systemPackages = [
(pkgs.writers.writeDashBin "gaslight-stream" ''
${pkgs.ffmpeg}/bin/ffmpeg -r 14 -s 640x480 -f video4linux2 -i /dev/video0 -f alsa -i default -c:v libx264 -preset ultrafast -c:a aac -f avi -
'')
(pkgs.writers.writeDashBin "gaslight-say" ''
voices="de
de+whisper"
echo "$@" | ${pkgs.espeak}/bin/espeak -v "$(echo "$voices" | ${pkgs.coreutils}/bin/shuf -n1)"
'')
(pkgs.writers.writeDashBin "gaslight-play" ''
set -o noglob
${pkgs.mpv}/bin/mpv --no-video "$1"
'')
];
}
/*
2022-03-10 21:52:12 +01:00
ssh machine gaslight-stream | mpv -
ssh machine gaslight-say "blablabla"
*/
2020-09-14 08:33:39 +02:00