{ config, lib, pkgs, ... }: { # home.packages = with pkgs; [ # beets # ]; # xdg.configFile."beets/config.yaml".source = ./beets/config.yaml; programs.beets = { enable = true; package = (pkgs.beets.override { pluginOverrides = { fish.enable = true; discogs.enable = true; the.enable = true; duplicates.enable = true; embedart.enable = true; fetchart.enable = true; mbsync.enable = true; missing.enable = true; unimported.enable = true; inline.enable = true; lastgenre.enable = true; albumtypes.enable = true; ftintitle.enable = true; plexupdate.enable = true; importadded.enable = true; edit.enable = true; info.enable = true; mpdupdate.enable = true; fuzzy.enable = true; }; }); mpdIntegration = { enableUpdate = true; }; settings = { directory = "/mnt/filez/media/Music"; library = "~/.config/beets/library.db"; asciify_paths = "yes"; import = { move = "yes"; copy = "no"; write = "yes"; autotag = "yes"; incremental = "yes"; incremental_skip_later = "yes"; resume = "ask"; quiet_fallback = "asis"; log = "~/beets.log"; none_rec_action = "asis"; duplicate_action = "merge"; default_action = "asis"; }; # plugins = "fish discogs the duplicates embedart fetchart mbsync missing unimported inline lastgenre albumtypes ftintitle plexupdate importadded edit info mpdupdate"; match = { ignored_media = [ "Data CD" "DVD" "DVD-Video" "Blu-ray" "HD-DVD" "VCD" "SVCD" "UMD" "VHS" ]; preferred = { countries = [ "US" "CA" "GB|UK" ]; original_year = "yes"; }; }; item_fields = { multidisc = "1 if disctotal > 1 else 0"; }; unimported = { ignore_extensions = "jpg png"; ignore_subdirectories = "NonMusic data temp"; }; discogs = { user_token = "FhRYPcATYbmLajnzLMTqzwovNGFvZeMdVxIHsAAn"; index_tracks = "yes"; append_style_genre = "yes"; separator = "; "; }; musicbrainz = { extra_tags = [ "year" "catalognum" "label" ]; genres = "yes"; }; aunique = { keys = "albumartist album"; disambiguators = "albumtype year label catalognum albumdisambig releasegroupdisambig"; bracket = "[]"; }; per_disc_numbering = "yes"; fetchart = { cautious = "yes"; }; albumtypes = { types = [ { ep = "EP"; } { single = "Single"; } { soundtrack = "OST"; } { live = "Live"; } { compilation = "Compilation"; } { remix = "Remix"; } ]; ignore_va = "compilation"; bracket = "[]"; }; lastgenre = { auto = "yes"; prefer_specific = "no"; count = 3; separator = "; "; force = "yes"; source = "album"; fallback = "Unclassified"; whitelist = "yes"; }; plex = { host = "media-server"; port = 32400; token = "DpUEsDtn43fiMEyzsTZ3"; }; paths = { default = "%the{$albumartist}%ifdef{artistdisambig,(\${artistdisambig})}/$album%aunique{}/%if{$multidisc,$disc-}$track - $title"; comp = "Various Artists/$album%aunique{}/$album%aunique{}/%if{$multidisc,$disc-}$track - $title"; }; importadded = { preserve_mtimes = "yes"; preserve_write_mtimes = "yes"; }; ui = { color = "yes"; }; album_fields = { format = ''formatList = [] for item in items: formatList.append(item.format) return formatList ''; }; }; }; }