git.iko.soy/typeable/nixpkgs
on master help sign in
Merge pull request #108275 from lovesegfault/beetsUnstable

beets: 1.4.9 -> unstable-2020-12-22

commit77d190f10931c1d06d87bf6d772bf65346c71777 authorBernardo Meurer <bernardo@meurer.org> dateSun 3 Jan 2021, 23:44 (6 years ago) parentd14652c264f798
17 files changed+236−233
pkgs/applications/audio/bs1770gain/default.nix−22 pkgs/tools/audio/beets/badfiles-plugin-nix-paths.patch+21 pkgs/tools/audio/beets/bash-completion-always-print.patch+43 pkgs/tools/audio/beets/compatibility-with-breaking-changes-to-the-ast-module.patch−55 pkgs/tools/audio/beets/convert-plugin-ffmpeg-path.patch+43 pkgs/tools/audio/beets/default.nix+97−82 pkgs/tools/audio/beets/keyfinder-default-bin.patch+5−15 pkgs/tools/audio/beets/mutagen-1.43.patch−40 pkgs/tools/audio/beets/alternatives-plugin.nix → pkgs/tools/audio/beets/plugins/alternatives.nix pkgs/tools/audio/beets/beet-check-tests.patch → pkgs/tools/audio/beets/plugins/check-tests.patch pkgs/tools/audio/beets/check-plugin.nix → pkgs/tools/audio/beets/plugins/check.nix pkgs/tools/audio/beets/copyartifacts-plugin.nix → pkgs/tools/audio/beets/plugins/copyartifacts.nix pkgs/tools/audio/beets/extrafiles-plugin.nix → pkgs/tools/audio/beets/plugins/extrafiles.nix pkgs/tools/audio/beets/replaygain-default-bs1770gain.patch−17 pkgs/tools/audio/beets/replaygain-default-ffmpeg.patch+26 pkgs/top-level/aliases.nix+1 pkgs/top-level/all-packages.nix−2
pkgs/applications/audio/bs1770gain/default.nixdeleted−22
@@ -1,22 +0,0 @@
1−{ stdenv, fetchurl, ffmpeg, sox }:
2−
3−stdenv.mkDerivation rec {
4− pname = "bs1770gain";
5− version = "0.5.2";
6−
7− src = fetchurl {
8− url = "mirror://sourceforge/bs1770gain/${pname}-${version}.tar.gz";
9− sha256 = "1p6yz5q7czyf9ard65sp4kawdlkg40cfscr3b24znymmhs3p7rbk";
10− };
11−
12− buildInputs = [ ffmpeg sox ];
13−
14− NIX_CFLAGS_COMPILE = "-Wno-error";
15−
16− meta = with stdenv.lib; {
17− description = "A audio/video loudness scanner implementing ITU-R BS.1770";
18− license = licenses.gpl2Plus;
19− homepage = "http://bs1770gain.sourceforge.net/";
20− platforms = platforms.all;
21− };
22−}
pkgs/tools/audio/beets/badfiles-plugin-nix-paths.patchnew file+21
@@ -0,0 +1,21 @@
1+diff --git i/beetsplug/badfiles.py w/beetsplug/badfiles.py
2+index 36b45de3..5208b696 100644
3+--- i/beetsplug/badfiles.py
4++++ w/beetsplug/badfiles.py
5+@@ -71,14 +71,14 @@ class BadFiles(BeetsPlugin):
6+ return status, errors, [line for line in output.split("\n") if line]
7+
8+ def check_mp3val(self, path):
9+- status, errors, output = self.run_command(["mp3val", path])
10++ status, errors, output = self.run_command(["@mp3val@/bin/mp3val", path])
11+ if status == 0:
12+ output = [line for line in output if line.startswith("WARNING:")]
13+ errors = len(output)
14+ return status, errors, output
15+
16+ def check_flac(self, path):
17+- return self.run_command(["flac", "-wst", path])
18++ return self.run_command(["@flac@/bin/flac", "-wst", path])
19+
20+ def check_custom(self, command):
21+ def checker(path):
pkgs/tools/audio/beets/bash-completion-always-print.patchnew file+43
@@ -0,0 +1,43 @@
1+diff --git i/beets/ui/commands.py w/beets/ui/commands.py
2+index 4d010f4b..0b023585 100755
3+--- i/beets/ui/commands.py
4++++ w/beets/ui/commands.py
5+@@ -1741,20 +1741,6 @@ default_commands.append(config_cmd)
6+ def print_completion(*args):
7+ for line in completion_script(default_commands + plugins.commands()):
8+ print_(line, end=u'')
9+- if not any(map(os.path.isfile, BASH_COMPLETION_PATHS)):
10+- log.warning(u'Warning: Unable to find the bash-completion package. '
11+- u'Command line completion might not work.')
12+-
13+-BASH_COMPLETION_PATHS = map(syspath, [
14+- u'/etc/bash_completion',
15+- u'/usr/share/bash-completion/bash_completion',
16+- u'/usr/local/share/bash-completion/bash_completion',
17+- # SmartOS
18+- u'/opt/local/share/bash-completion/bash_completion',
19+- # Homebrew (before bash-completion2)
20+- u'/usr/local/etc/bash_completion',
21+-])
22+-
23+
24+ def completion_script(commands):
25+ """Yield the full completion shell script as strings.
26+diff --git i/test/test_ui.py w/test/test_ui.py
27+index 5cfed1fd..9d3dc458 100644
28+--- i/test/test_ui.py
29++++ w/test/test_ui.py
30+@@ -1230,12 +1230,7 @@ class CompletionTest(_common.TestCase, TestHelper):
31+ stdout=subprocess.PIPE, env=env)
32+
33+ # Load bash_completion library.
34+- for path in commands.BASH_COMPLETION_PATHS:
35+- if os.path.exists(util.syspath(path)):
36+- bash_completion = path
37+- break
38+- else:
39+- self.skipTest(u'bash-completion script not found')
40++ self.skipTest(u'bash-completion script not found')
41+ try:
42+ with open(util.syspath(bash_completion), 'rb') as f:
43+ tester.stdin.writelines(f)
pkgs/tools/audio/beets/compatibility-with-breaking-changes-to-the-ast-module.patchdeleted−55
@@ -1,55 +0,0 @@
1−From 771ce704ebeac4cd9bd74b3ddde9fb01f3dc7eb4 Mon Sep 17 00:00:00 2001
2−From: wisp3rwind <17089248+wisp3rwind@users.noreply.github.com>
3−Date: Tue, 9 Jun 2020 19:34:31 +0200
4−Subject: [PATCH] compatibility with breaking changes to the ast module
5−
6−new in 3.10, also backported to 3.8 and 3.9: https://github.com/python/cpython/pull/20649
7−In fact, our generation of some Literals has been invalid since Python
8−3.4, fix that too.
9−---
10− beets/util/functemplate.py | 29 ++++++++++++++++++++---------
11− 1 file changed, 20 insertions(+), 9 deletions(-)
12−
13−diff --git a/beets/util/functemplate.py b/beets/util/functemplate.py
14−index af22b790..266534a9 100644
15−--- a/beets/util/functemplate.py
16−+++ b/beets/util/functemplate.py
17−@@ -73,15 +73,26 @@ def ex_literal(val):
18− """An int, float, long, bool, string, or None literal with the given
19− value.
20− """
21−- if val is None:
22−- return ast.Name('None', ast.Load())
23−- elif isinstance(val, six.integer_types):
24−- return ast.Num(val)
25−- elif isinstance(val, bool):
26−- return ast.Name(bytes(val), ast.Load())
27−- elif isinstance(val, six.string_types):
28−- return ast.Str(val)
29−- raise TypeError(u'no literal for {0}'.format(type(val)))
30−+ if sys.version_info[:2] < (3, 4):
31−+ if val is None:
32−+ return ast.Name('None', ast.Load())
33−+ elif isinstance(val, six.integer_types):
34−+ return ast.Num(val)
35−+ elif isinstance(val, bool):
36−+ return ast.Name(bytes(val), ast.Load())
37−+ elif isinstance(val, six.string_types):
38−+ return ast.Str(val)
39−+ raise TypeError(u'no literal for {0}'.format(type(val)))
40−+ elif sys.version_info[:2] < (3, 6):
41−+ if val in [None, True, False]:
42−+ return ast.NameConstant(val)
43−+ elif isinstance(val, six.integer_types):
44−+ return ast.Num(val)
45−+ elif isinstance(val, six.string_types):
46−+ return ast.Str(val)
47−+ raise TypeError(u'no literal for {0}'.format(type(val)))
48−+ else:
49−+ return ast.Constant(val)
50−
51−
52− def ex_varassign(name, expr):
53−--
54−2.27.0
55−
pkgs/tools/audio/beets/convert-plugin-ffmpeg-path.patchnew file+43
@@ -0,0 +1,43 @@
1+diff --git i/beetsplug/convert.py w/beetsplug/convert.py
2+index 70363f6e..2962aa4f 100644
3+--- i/beetsplug/convert.py
4++++ w/beetsplug/convert.py
5+@@ -81,7 +81,7 @@ def get_format(fmt=None):
6+ command = config['convert']['command'].as_str()
7+ elif 'opts' in keys:
8+ # Undocumented option for backwards compatibility with < 1.3.1.
9+- command = u'ffmpeg -i $source -y {0} $dest'.format(
10++ command = u'@ffmpeg@/bin/ffmpeg -i $source -y {0} $dest'.format(
11+ config['convert']['opts'].as_str()
12+ )
13+ if 'extension' in keys:
14+@@ -121,22 +121,22 @@ class ConvertPlugin(BeetsPlugin):
15+ u'id3v23': u'inherit',
16+ u'formats': {
17+ u'aac': {
18+- u'command': u'ffmpeg -i $source -y -vn -acodec aac '
19++ u'command': u'@ffmpeg@/bin/ffmpeg -i $source -y -vn -acodec aac '
20+ u'-aq 1 $dest',
21+ u'extension': u'm4a',
22+ },
23+ u'alac': {
24+- u'command': u'ffmpeg -i $source -y -vn -acodec alac $dest',
25++ u'command': u'@ffmpeg@/bin/ffmpeg -i $source -y -vn -acodec alac $dest',
26+ u'extension': u'm4a',
27+ },
28+- u'flac': u'ffmpeg -i $source -y -vn -acodec flac $dest',
29+- u'mp3': u'ffmpeg -i $source -y -vn -aq 2 $dest',
30++ u'flac': u'@ffmpeg@/bin/ffmpeg -i $source -y -vn -acodec flac $dest',
31++ u'mp3': u'@ffmpeg@/bin/ffmpeg -i $source -y -vn -aq 2 $dest',
32+ u'opus':
33+- u'ffmpeg -i $source -y -vn -acodec libopus -ab 96k $dest',
34++ u'@ffmpeg@/bin/ffmpeg -i $source -y -vn -acodec libopus -ab 96k $dest',
35+ u'ogg':
36+- u'ffmpeg -i $source -y -vn -acodec libvorbis -aq 3 $dest',
37++ u'@ffmpeg@/bin/ffmpeg -i $source -y -vn -acodec libvorbis -aq 3 $dest',
38+ u'wma':
39+- u'ffmpeg -i $source -y -vn -acodec wmav2 -vn $dest',
40++ u'@ffmpeg@/bin/ffmpeg -i $source -y -vn -acodec wmav2 -vn $dest',
41+ },
42+ u'max_bitrate': 500,
43+ u'auto': False,
pkgs/tools/audio/beets/default.nix+97−82
@@ -1,4 +1,4 @@
1−{ stdenv, fetchFromGitHub, writeScript, glibcLocales, diffPlugins
1+{ stdenv, lib, fetchFromGitHub, writeScript, glibcLocales, diffPlugins, substituteAll
22, pythonPackages, imagemagick, gobject-introspection, gst_all_1
33, runtimeShell
44, fetchpatch
@@ -6,61 +6,70 @@
66# Attributes needed for tests of the external plugins
77, callPackage, beets
88
9−, enableAbsubmit ? stdenv.lib.elem stdenv.hostPlatform.system essentia-extractor.meta.platforms, essentia-extractor ? null
10−, enableAcousticbrainz ? true
11−, enableAcoustid ? true
12−, enableBadfiles ? true, flac ? null, mp3val ? null
13−, enableConvert ? true, ffmpeg_3 ? null
14−, enableDiscogs ? true
15−, enableEmbyupdate ? true
16−, enableFetchart ? true
17−, enableGmusic ? true
18−, enableKeyfinder ? true, keyfinder-cli ? null
19−, enableKodiupdate ? true
20−, enableLastfm ? true
21−, enableLoadext ? true
22−, enableMpd ? true
23−, enablePlaylist ? true
24−, enableReplaygain ? true, bs1770gain ? null
25−, enableSonosUpdate ? true
26−, enableSubsonicupdate ? true
27−, enableThumbnails ? true
28−, enableWeb ? true
9+, enableAbsubmit ? lib.elem stdenv.hostPlatform.system essentia-extractor.meta.platforms, essentia-extractor ? null
10+, enableAcousticbrainz ? true
11+, enableAcoustid ? true
12+, enableBadfiles ? true, flac ? null, mp3val ? null
13+, enableBeatport ? true
14+, enableBpsync ? true
15+, enableConvert ? true, ffmpeg ? null
16+, enableDeezer ? true
17+, enableDiscogs ? true
18+, enableEmbyupdate ? true
19+, enableFetchart ? true
20+, enableGmusic ? true
21+, enableKeyfinder ? true, keyfinder-cli ? null
22+, enableKodiupdate ? true
23+, enableLastfm ? true
24+, enableLoadext ? true
25+, enableMpd ? true
26+, enablePlaylist ? true
27+, enableReplaygain ? true
28+, enableSonosUpdate ? true
29+, enableSubsonicplaylist ? true
30+, enableSubsonicupdate ? true
31+, enableThumbnails ? true
32+, enableWeb ? true
2933
3034# External plugins
31−, enableAlternatives ? false
32−, enableCheck ? false, liboggz ? null
33−, enableCopyArtifacts ? false
34−, enableExtraFiles ? false
35+, enableAlternatives ? false
36+, enableCheck ? false, liboggz ? null
37+, enableCopyArtifacts ? false
38+, enableExtraFiles ? false
3539
3640, bashInteractive, bash-completion
3741}:
3842
39−assert enableAbsubmit -> essentia-extractor != null;
40−assert enableAcoustid -> pythonPackages.pyacoustid != null;
43+assert enableAbsubmit -> essentia-extractor != null;
44+assert enableAcoustid -> pythonPackages.pyacoustid != null;
4145assert enableBadfiles -> flac != null && mp3val != null;
46+assert enableBeatport -> pythonPackages.requests_oauthlib != null;
47+assert enableBpsync -> enableBeatport;
4248assert enableCheck -> flac != null && mp3val != null && liboggz != null;
43−assert enableConvert -> ffmpeg_3 != null;
44−assert enableDiscogs -> pythonPackages.discogs_client != null;
45−assert enableFetchart -> pythonPackages.responses != null;
46−assert enableGmusic -> pythonPackages.gmusicapi != null;
47−assert enableKeyfinder -> keyfinder-cli != null;
48−assert enableLastfm -> pythonPackages.pylast != null;
49−assert enableMpd -> pythonPackages.mpd2 != null;
50−assert enableReplaygain -> bs1770gain != null;
51−assert enableSonosUpdate -> pythonPackages.soco != null;
52−assert enableThumbnails -> pythonPackages.pyxdg != null;
53−assert enableWeb -> pythonPackages.flask != null;
54−
55−with stdenv.lib;
49+assert enableConvert -> ffmpeg != null;
50+assert enableDiscogs -> pythonPackages.discogs_client != null;
51+assert enableFetchart -> pythonPackages.responses != null;
52+assert enableGmusic -> pythonPackages.gmusicapi != null;
53+assert enableKeyfinder -> keyfinder-cli != null;
54+assert enableLastfm -> pythonPackages.pylast != null;
55+assert enableMpd -> pythonPackages.mpd2 != null;
56+assert enableReplaygain -> ffmpeg != null;
57+assert enableSonosUpdate -> pythonPackages.soco != null;
58+assert enableThumbnails -> pythonPackages.pyxdg != null;
59+assert enableWeb -> pythonPackages.flask != null;
60+
61+with lib;
5662
5763let
5864 optionalPlugins = {
5965 absubmit = enableAbsubmit;
6066 acousticbrainz = enableAcousticbrainz;
6167 badfiles = enableBadfiles;
68+ beatport = enableBeatport;
69+ bpsync = enableBpsync;
6270 chroma = enableAcoustid;
6371 convert = enableConvert;
72+ deezer = enableDeezer;
6473 discogs = enableDiscogs;
6574 embyupdate = enableEmbyupdate;
6675 fetchart = enableFetchart;
@@ -75,18 +84,19 @@ let
7584 playlist = enablePlaylist;
7685 replaygain = enableReplaygain;
7786 sonosupdate = enableSonosUpdate;
87+ subsonicplaylist = enableSubsonicplaylist;
7888 subsonicupdate = enableSubsonicupdate;
7989 thumbnails = enableThumbnails;
8090 web = enableWeb;
8191 };
8292
8393 pluginsWithoutDeps = [
84− "beatport" "bench" "bpd" "bpm" "bucket" "cue" "duplicates" "edit" "embedart"
85− "export" "filefilter" "freedesktop" "fromfilename" "ftintitle" "fuzzy"
94+ "bench" "bpd" "bpm" "bucket" "cue" "duplicates" "edit" "embedart"
95+ "export" "filefilter" "fish" "freedesktop" "fromfilename" "ftintitle" "fuzzy"
8696 "hook" "ihate" "importadded" "importfeeds" "info" "inline" "ipfs" "lyrics"
87− "mbcollection" "mbsubmit" "mbsync" "metasync" "missing" "permissions" "play"
97+ "mbcollection" "mbsubmit" "mbsync" "metasync" "missing" "parentwork" "permissions" "play"
8898 "plexupdate" "random" "rewrite" "scrub" "smartplaylist" "spotify" "the"
89− "types" "zero"
99+ "types" "unimported" "zero"
90100 ];
91101
92102 enabledOptionalPlugins = attrNames (filterAttrs (_: id) optionalPlugins);
@@ -102,28 +112,33 @@ let
102112 enableAlternatives = false;
103113 enableCopyArtifacts = false;
104114 enableExtraFiles = false;
105− }).overrideAttrs (stdenv.lib.const {
115+ }).overrideAttrs (const {
106116 doInstallCheck = false;
107117 });
108118
109119 pluginArgs = externalTestArgs // { inherit pythonPackages; };
110120
111121 plugins = {
112− alternatives = callPackage ./alternatives-plugin.nix pluginArgs;
113− check = callPackage ./check-plugin.nix pluginArgs;
114− copyartifacts = callPackage ./copyartifacts-plugin.nix pluginArgs;
115− extrafiles = callPackage ./extrafiles-plugin.nix pluginArgs;
122+ alternatives = callPackage ./plugins/alternatives.nix pluginArgs;
123+ check = callPackage ./plugins/check.nix pluginArgs;
124+ copyartifacts = callPackage ./plugins/copyartifacts.nix pluginArgs;
125+ extrafiles = callPackage ./plugins/extrafiles.nix pluginArgs;
116126 };
117127
118128in pythonPackages.buildPythonApplication rec {
119129 pname = "beets";
120− version = "1.4.9";
130+ # While there is a stable version, 1.4.9, it is more than 1000 commits behind
131+ # master and lacks many bug fixes and improvements[1]. Also important,
132+ # unstable does not require bs1770gain[2].
133+ # [1]: https://discourse.beets.io/t/forming-a-beets-core-team/639
134+ # [2]: https://github.com/NixOS/nixpkgs/pull/90504
135+ version = "unstable-2020-12-22";
121136
122137 src = fetchFromGitHub {
123138 owner = "beetbox";
124139 repo = "beets";
125− rev = "v${version}";
126− sha256 = "1qxdqbzvz97zgykzdwn78g2xyxmg0q2jdb12dnjnrwvhmjv67vi8";
140+ rev = "53dcb24d10788897f20c341774b474808ec2c0b6";
141+ sha256 = "sha256-P++NA13T2TRHW3Se10np8BSe/WRBYAKRte5xKoHKW50=";
127142 };
128143
129144 propagatedBuildInputs = [
@@ -137,19 +152,25 @@ in pythonPackages.buildPythonApplication rec {
137152 pythonPackages.unidecode
138153 pythonPackages.gst-python
139154 pythonPackages.pygobject3
155+ pythonPackages.reflink
156+ pythonPackages.confuse
157+ pythonPackages.mediafile
140158 gobject-introspection
141159 ] ++ optional enableAbsubmit essentia-extractor
142160 ++ optional enableAcoustid pythonPackages.pyacoustid
161+ ++ optional enableBeatport pythonPackages.requests_oauthlib
143162 ++ optional (enableFetchart
163+ || enableDeezer
144164 || enableEmbyupdate
145165 || enableKodiupdate
146166 || enableLoadext
147167 || enablePlaylist
168+ || enableSubsonicplaylist
148169 || enableSubsonicupdate
149170 || enableAcousticbrainz)
150171 pythonPackages.requests
151172 ++ optional enableCheck plugins.check
152− ++ optional enableConvert ffmpeg_3
173+ ++ optional enableConvert ffmpeg
153174 ++ optional enableDiscogs pythonPackages.discogs_client
154175 ++ optional enableGmusic pythonPackages.gmusicapi
155176 ++ optional enableKeyfinder keyfinder-cli
@@ -187,41 +208,35 @@ in pythonPackages.buildPythonApplication rec {
187208 ];
188209
189210 patches = [
190− ./replaygain-default-bs1770gain.patch
211+ # Bash completion fix for Nix
212+ ./bash-completion-always-print.patch
213+ # From some reason upstream assumes the program 'keyfinder-cli' is located
214+ # in the path as `KeyFinder`
191215 ./keyfinder-default-bin.patch
192− ./mutagen-1.43.patch
193− (fetchpatch {
194− # Fixes failing testcases around the werkzeug component; can dropped after 1.4.9
195− url = "https://github.com/beetbox/beets/commit/d43d54e21cde97f57f19486925ab56b419254cc8.patch";
196− sha256 = "13n2gzmcgfi0m2ycl2r1hpczgksplnkc3y6b66vg57rx5y8nnv5c";
216+ ]
217+ # We need to force ffmpeg as the default, since we do not package
218+ # bs1770gain, and set the absolute path there, to avoid impurities.
219+ ++ lib.optional enableReplaygain (substituteAll {
220+ src = ./replaygain-default-ffmpeg.patch;
221+ ffmpeg = getBin ffmpeg;
197222 })
223+ # Put absolute Nix paths in place
224+ ++ lib.optional enableConvert (substituteAll {
225+ src = ./convert-plugin-ffmpeg-path.patch;
226+ ffmpeg = getBin ffmpeg;
227+ })
228+ ++ lib.optional enableBadfiles (substituteAll {
229+ src = ./badfiles-plugin-nix-paths.patch;
230+ inherit mp3val flac;
231+ })
232+ ;
198233
199− # Fixes 548 tests due to breaking changes to the ast module
200− # https://github.com/beetbox/beets/pull/3621
201− # Can be dropped after 1.4.9
202− ./compatibility-with-breaking-changes-to-the-ast-module.patch
203− ];
204−
234+ # Disable failing tests
205235 postPatch = ''
206236 sed -i -e '/assertIn.*item.*path/d' test/test_info.py
207237 echo echo completion tests passed > test/rsrc/test_completion.sh
208238
209− sed -i -e '/^BASH_COMPLETION_PATHS *=/,/^])$/ {
210− /^])$/i u"${completion}"
211− }' beets/ui/commands.py
212− '' + optionalString enableBadfiles ''
213− sed -i -e '/self\.run_command(\[/ {
214− s,"flac","${flac.bin}/bin/flac",
215− s,"mp3val","${mp3val}/bin/mp3val",
216− }' beetsplug/badfiles.py
217− '' + optionalString enableConvert ''
218− sed -i -e 's,\(util\.command_output(\)\([^)]\+\)),\1[b"${ffmpeg_3.bin}/bin/ffmpeg" if args[0] == b"ffmpeg" else args[0]] + \2[1:]),' beetsplug/convert.py
219− '' + optionalString enableReplaygain ''
220− sed -i -re '
221− s!^( *cmd *= *b?['\'''"])(bs1770gain['\'''"])!\1${bs1770gain}/bin/\2!
222− ' beetsplug/replaygain.py
223− sed -i -e 's/if has_program.*bs1770gain.*:/if True:/' \
224− test/test_replaygain.py
239+ sed -i -e 's/len(mf.images)/0/' test/test_zero.py
225240 '';
226241
227242 postInstall = ''
@@ -281,7 +296,7 @@ in pythonPackages.buildPythonApplication rec {
281296 description = "Music tagger and library organizer";
282297 homepage = "http://beets.io";
283298 license = licenses.mit;
284− maintainers = with maintainers; [ aszlig domenkozar pjones ];
299+ maintainers = with maintainers; [ aszlig domenkozar doronbehar lovesegfault pjones ];
285300 platforms = platforms.linux;
286301 };
287302}
pkgs/tools/audio/beets/keyfinder-default-bin.patch+5−15
@@ -1,8 +1,8 @@
11diff --git a/beetsplug/keyfinder.py b/beetsplug/keyfinder.py
2−index 34a4abc..59e8539 100644
2+index 702003f0..08689cd8 100644
33--- a/beetsplug/keyfinder.py
44+++ b/beetsplug/keyfinder.py
5−@@ -30,7 +30,7 @@ class KeyFinderPlugin(BeetsPlugin):
5+@@ -31,7 +31,7 @@ class KeyFinderPlugin(BeetsPlugin):
66 def __init__(self):
77 super(KeyFinderPlugin, self).__init__()
88 self.config.add({
@@ -11,18 +11,8 @@ index 34a4abc..59e8539 100644
1111 u'auto': True,
1212 u'overwrite': False,
1313 })
14−@@ -59,8 +59,7 @@ class KeyFinderPlugin(BeetsPlugin):
15− continue
16−
17− try:
18−- output = util.command_output([bin, '-f',
19−- util.syspath(item.path)])
20−+ output = util.command_output([bin, util.syspath(item.path)])
21− except (subprocess.CalledProcessError, OSError) as exc:
22− self._log.error(u'execution failed: {0}', exc)
23− continue
2414diff --git a/test/test_keyfinder.py b/test/test_keyfinder.py
25−index 57e2bcd..c1ee916 100644
15+index c8735e47..d7d670a4 100644
2616--- a/test/test_keyfinder.py
2717+++ b/test/test_keyfinder.py
2818@@ -44,7 +44,7 @@ class KeyFinderTest(unittest.TestCase, TestHelper):
@@ -31,6 +21,6 @@ index 57e2bcd..c1ee916 100644
3121 command_output.assert_called_with(
3222- ['KeyFinder', '-f', util.syspath(item.path)])
3323+ ['keyfinder-cli', util.syspath(item.path)])
34−
24+
3525 def test_add_key_on_import(self, command_output):
36− command_output.return_value = 'dbm'
26+ command_output.return_value = util.CommandOutput(b"dbm", b"")
pkgs/tools/audio/beets/mutagen-1.43.patchdeleted−40
@@ -1,40 +0,0 @@
1−Backport
2−https://github.com/beetbox/mediafile/commit/b3343c4ee08d1251ae5e2344401a2f5892b4e868
3−https://github.com/beetbox/mediafile/commit/d2fc3b59f77c515b02dfe7ad936f89264375d2b4
4−to Beets 1.4.9.
5−
6−diff --git i/setup.py w/setup.py
7−index 79278f8b..b8d60687 100755
8−--- i/setup.py
9−+++ w/setup.py
10−@@ -87,7 +87,7 @@ setup(
11−
12− install_requires=[
13− 'six>=1.9',
14−- 'mutagen>=1.33',
15−+ 'mutagen>=1.43',
16− 'unidecode',
17− 'musicbrainzngs>=0.4',
18− 'pyyaml',
19−diff --git i/test/test_mediafile.py w/test/test_mediafile.py
20−index 36a2c53a..0ddde44e 100644
21−--- i/test/test_mediafile.py
22−+++ w/test/test_mediafile.py
23−@@ -888,7 +888,7 @@ class WavpackTest(ReadWriteTestBase, unittest.TestCase):
24− 'bitrate': 109312,
25− 'format': u'WavPack',
26− 'samplerate': 44100,
27−- 'bitdepth': 0,
28−+ 'bitdepth': 16,
29− 'channels': 1,
30− }
31−
32−@@ -912,7 +912,7 @@ class AIFFTest(ReadWriteTestBase, unittest.TestCase):
33− 'bitrate': 705600,
34− 'format': u'AIFF',
35− 'samplerate': 44100,
36−- 'bitdepth': 0,
37−+ 'bitdepth': 16,
38− 'channels': 1,
39− }
40−
pkgs/tools/audio/beets/alternatives-plugin.nix → pkgs/tools/audio/beets/plugins/alternatives.nixrenamed

The content is the same.

pkgs/tools/audio/beets/beet-check-tests.patch → pkgs/tools/audio/beets/plugins/check-tests.patchrenamed

The content is the same.

pkgs/tools/audio/beets/check-plugin.nix → pkgs/tools/audio/beets/plugins/check.nixrenamed

The content is the same.

pkgs/tools/audio/beets/copyartifacts-plugin.nix → pkgs/tools/audio/beets/plugins/copyartifacts.nixrenamed

The content is the same.

pkgs/tools/audio/beets/extrafiles-plugin.nix → pkgs/tools/audio/beets/plugins/extrafiles.nixrenamed

The content is the same.

pkgs/tools/audio/beets/replaygain-default-bs1770gain.patchdeleted−17
@@ -1,17 +0,0 @@
1−diff --git a/beetsplug/replaygain.py b/beetsplug/replaygain.py
2−index 40b3a3a..9b54a5a 100644
3−--- a/beetsplug/replaygain.py
4−+++ b/beetsplug/replaygain.py
5−@@ -627,11 +627,10 @@ class ReplayGainPlugin(BeetsPlugin):
6− super(ReplayGainPlugin, self).__init__()
7− self.import_stages = [self.imported]
8−
9−- # default backend is 'command' for backward-compatibility.
10− self.config.add({
11− 'overwrite': False,
12− 'auto': True,
13−- 'backend': u'command',
14−+ 'backend': u'bs1770gain',
15− 'targetlevel': 89,
16− })
17−
pkgs/tools/audio/beets/replaygain-default-ffmpeg.patchnew file+26
@@ -0,0 +1,26 @@
1+diff --git i/beetsplug/replaygain.py w/beetsplug/replaygain.py
2+index 9d6fa23c..c5800039 100644
3+--- i/beetsplug/replaygain.py
4++++ w/beetsplug/replaygain.py
5+@@ -391,7 +391,7 @@ class FfmpegBackend(Backend):
6+
7+ def __init__(self, config, log):
8+ super(FfmpegBackend, self).__init__(config, log)
9+- self._ffmpeg_path = "ffmpeg"
10++ self._ffmpeg_path = "@ffmpeg@/bin/ffmpeg"
11+
12+ # check that ffmpeg is installed
13+ try:
14+@@ -1228,11 +1228,10 @@ class ReplayGainPlugin(BeetsPlugin):
15+ def __init__(self):
16+ super(ReplayGainPlugin, self).__init__()
17+
18+- # default backend is 'command' for backward-compatibility.
19+ self.config.add({
20+ 'overwrite': False,
21+ 'auto': True,
22+- 'backend': u'command',
23++ 'backend': u'ffmpeg',
24+ 'threads': cpu_count(),
25+ 'parallel_on_import': False,
26+ 'per_disc': False,
pkgs/top-level/aliases.nix+1
@@ -78,6 +78,7 @@ mapAliases ({
7878 bittorrentSync = throw "bittorrentSync has been deprecated by resilio-sync."; # added 2019-06-03
7979 bittorrentSync14 = throw "bittorrentSync14 has been deprecated by resilio-sync."; # added 2019-06-03
8080 bittorrentSync20 = throw "bittorrentSync20 has been deprecated by resilio-sync."; # added 2019-06-03
81+ bs1770gain = throw "bs1770gain has been removed from nixpkgs, as it had no maintainer or reverse dependencies."; # added 2021-01-02
8182 btc1 = throw "btc1 has been removed, it was abandoned by upstream"; # added 2020-11-03
8283 buildPerlPackage = perlPackages.buildPerlPackage; # added 2018-10-12
8384 buildGo112Package = throw "buildGo112Package has been removed"; # added 2020-04-26
pkgs/top-level/all-packages.nix−2
@@ -20801,8 +20801,6 @@ in
2080120801
2080220802 bristol = callPackage ../applications/audio/bristol { };
2080320803
20804− bs1770gain = callPackage ../applications/audio/bs1770gain { };
20805−
2080620804 bjumblr = callPackage ../applications/audio/bjumblr { };
2080720805
2080820806 bschaffl = callPackage ../applications/audio/bschaffl { };