about summary refs log tree commit diff
path: root/pkgs/tools/audio
diff options
context:
space:
mode:
authorEmery Hemingway <emery@vfemail.net>2015-01-19 13:47:11 -0500
committerEmery Hemingway <emery@vfemail.net>2015-01-21 09:49:20 -0500
commite563ada091a0fc85d18fa07743bdb09c90f67f37 (patch)
treeb1549170b54d0fd179eff09665892153075feef3 /pkgs/tools/audio
parentb89fbb61883f600bff4b6ff3615cfa4b542d6470 (diff)
downloadnixlib-e563ada091a0fc85d18fa07743bdb09c90f67f37.tar
nixlib-e563ada091a0fc85d18fa07743bdb09c90f67f37.tar.gz
nixlib-e563ada091a0fc85d18fa07743bdb09c90f67f37.tar.bz2
nixlib-e563ada091a0fc85d18fa07743bdb09c90f67f37.tar.lz
nixlib-e563ada091a0fc85d18fa07743bdb09c90f67f37.tar.xz
nixlib-e563ada091a0fc85d18fa07743bdb09c90f67f37.tar.zst
nixlib-e563ada091a0fc85d18fa07743bdb09c90f67f37.zip
dir2opus: initial package at 0.12.1
Diffstat (limited to 'pkgs/tools/audio')
-rw-r--r--pkgs/tools/audio/dir2opus/default.nix33
1 files changed, 33 insertions, 0 deletions
diff --git a/pkgs/tools/audio/dir2opus/default.nix b/pkgs/tools/audio/dir2opus/default.nix
new file mode 100644
index 000000000000..bc3eaf9bf534
--- /dev/null
+++ b/pkgs/tools/audio/dir2opus/default.nix
@@ -0,0 +1,33 @@
+{ stdenv, fetchurl, python, mutagen, wrapPython, opusTools }:
+
+let version = "0.12.1"; in
+stdenv.mkDerivation rec {
+  name = "dir2opus-${version}";
+
+  pythonPath = [ mutagen ];
+  buildInputs = [ wrapPython ];
+  propagatedBuildInputs = [ opusTools ];
+
+  src = fetchurl {
+    url = "https://github.com/ehmry/dir2opus/archive/${version}.tar.gz";
+    name = "${name}.tar.gz";
+    sha256 = "1d6x3qfcj5lfmc8gzna1vrr7fl31i86ha8l4nz5987rx57fgwf0q";
+  };
+
+  postPatch = "sed -i -e 's|#!/usr/bin/python|#!${python}/bin/python|' dir2opus";
+
+  installPhase =
+    ''
+      mkdir -p $out/bin $out/share/man/man1
+      cp dir2opus $out/bin
+      cp dir2opus.1 $out/share/man/man1
+    '';
+
+  postFixup = "wrapPythonPrograms";
+
+  meta = with stdenv.lib;
+    { homepage = https://github.com/ehmry/dir2opus;
+      maintainers = [ maintainers.emery ];
+      license = licenses.gpl2;
+    };
+}
\ No newline at end of file