diff --git a/modules/audio.nix b/modules/audio.nix index 4230762..3d0116d 100644 --- a/modules/audio.nix +++ b/modules/audio.nix @@ -1,6 +1,14 @@ { config, lib, pkgs, ... }: -{ +with pkgs; + +# HACK Replace youtube-dl with yt-dlp in mopidy-youtube +let + mopidy-youtube-yt_dlp = mopidy-youtube.overrideAttrs (old: rec { + propagatedBuildInputs = old.propagatedBuildInputs + ++ [ python3.pkgs.yt-dlp ]; + }); +in { # Configure pipewire as sound server services.pipewire = { enable = true; @@ -32,12 +40,8 @@ # Set up Mopidy services.mopidy = { enable = true; - extensionPackages = with pkgs; [ - mopidy-mpd - mopidy-youtube - mopidy-somafm - mopidy-local - ]; + extensionPackages = + [ mopidy-mpd mopidy-youtube-yt_dlp mopidy-somafm mopidy-local ]; configuration = '' [audio] mixer_volume = @@ -71,6 +75,7 @@ [youtube] allow_cache = true search_results = 50 + youtube_dl_package = yt_dlp [somafm] encoding = aac diff --git a/modules/software.nix b/modules/software.nix index c2109f4..2a46808 100644 --- a/modules/software.nix +++ b/modules/software.nix @@ -78,7 +78,7 @@ in { mpv patched-webtorrent-cli deluge - youtube-dl-light + yt-dlp-light calibre beets # File management