3
0
Fork 0
forked from mirrors/nixpkgs

beets: add copyartifacts plugin

This commit is contained in:
Michal Rus 2016-09-10 01:43:42 +02:00
parent 6b20d5b75e
commit 37a61d357a
No known key found for this signature in database
GPG key ID: 396762D2C75A20A7
2 changed files with 29 additions and 1 deletions

View file

@ -0,0 +1,24 @@
{ stdenv, buildPythonApplication, fetchFromGitHub, pythonPackages }:
buildPythonApplication rec {
name = "beets-copyartifacts";
src = fetchFromGitHub {
repo = "beets-copyartifacts";
owner = "sbarakat";
rev = "dac4a1605111e24bb5b498aa84cead7c87480834";
sha256 = "0p5cskfgqinzh48a58hw56f96g9lar3k3g2p0ip1m9kawzf6axng";
};
postPatch = ''
sed -i -e '/install_requires/,/\]/{/beets/d}' setup.py
sed -i -e '/namespace_packages/d' setup.py
printf 'from pkgutil import extend_path\n__path__ = extend_path(__path__, __name__)\n' >beetsplug/__init__.py
'';
meta = {
description = "Beets plugin to move non-music files during the import process";
homepage = "https://github.com/sbarakat/beets-copyartifacts";
license = stdenv.lib.licenses.mit;
};
}

View file

@ -16,6 +16,7 @@
# External plugins
, enableAlternatives ? false
, enableCopyArtifacts ? false
, bashInteractive, bashCompletion
}:
@ -104,6 +105,9 @@ in buildPythonApplication rec {
++ optional enableWeb pythonPackages.flask
++ optional enableAlternatives (import ./alternatives-plugin.nix {
inherit stdenv buildPythonApplication pythonPackages fetchFromGitHub;
})
++ optional enableCopyArtifacts (import ./copyartifacts-plugin.nix {
inherit stdenv buildPythonApplication pythonPackages fetchFromGitHub;
});
buildInputs = with pythonPackages; [