summary refs log tree commit diff
diff options
context:
space:
mode:
authorJack Kelly <jack@jackkelly.name>2018-04-08 11:42:13 +1000
committerJack Kelly <jack@jackkelly.name>2018-04-08 20:44:05 +1000
commite1f6778e115e255ad1ffb5661a3b6348c8293dc9 (patch)
tree987e7e73c9b4c8aafe1a8dcdaffb301d961d5bde
parentbabbf2ac5cc665a6597674e8c7a9fd3cf8a63144 (diff)
downloadnixpkgs-e1f6778e115e255ad1ffb5661a3b6348c8293dc9.tar
nixpkgs-e1f6778e115e255ad1ffb5661a3b6348c8293dc9.tar.gz
nixpkgs-e1f6778e115e255ad1ffb5661a3b6348c8293dc9.tar.bz2
nixpkgs-e1f6778e115e255ad1ffb5661a3b6348c8293dc9.tar.lz
nixpkgs-e1f6778e115e255ad1ffb5661a3b6348c8293dc9.tar.xz
nixpkgs-e1f6778e115e255ad1ffb5661a3b6348c8293dc9.tar.zst
nixpkgs-e1f6778e115e255ad1ffb5661a3b6348c8293dc9.zip
crip: init at 3.9
-rw-r--r--pkgs/applications/audio/crip/default.nix68
-rw-r--r--pkgs/top-level/all-packages.nix2
2 files changed, 70 insertions, 0 deletions
diff --git a/pkgs/applications/audio/crip/default.nix b/pkgs/applications/audio/crip/default.nix
new file mode 100644
index 00000000000..0383af06795
--- /dev/null
+++ b/pkgs/applications/audio/crip/default.nix
@@ -0,0 +1,68 @@
+{ stdenv
+, fetchurl
+, makeWrapper
+
+, perl
+, perlPackages
+
+, cdparanoia
+, coreutils
+, eject
+, flac
+, gnugrep
+, nano
+, sox
+, vorbis-tools
+, vorbisgain
+, which
+}:
+
+with stdenv.lib;
+
+stdenv.mkDerivation rec {
+  name = "crip-3.9";
+  src = fetchurl {
+    url = "http://bach.dynet.com/crip/src/${name}.tar.gz";
+    sha256 = "0pk9152wll6fmkj1pki3fz3ijlf06jyk32v31yarwvdkwrk7s9xz";
+  };
+
+  buildInputs = [ perl perlPackages.CDDB_get ];
+  nativeBuildInputs = [ makeWrapper ];
+
+  toolDeps = makeBinPath [
+    cdparanoia
+    coreutils
+    eject
+    flac
+    gnugrep
+    sox
+    vorbis-tools
+    vorbisgain
+    which
+  ];
+
+  scripts = [ "crip" "editcomment" "editfilenames" ];
+
+  installPhase = ''
+    mkdir -p $out/bin/
+
+    for script in ${escapeShellArgs scripts}; do
+      cp $script $out/bin/
+
+      substituteInPlace $out/bin/$script \
+        --replace '$editor = "vim";' '$editor = "${nano}/bin/nano";'
+
+      wrapProgram $out/bin/$script \
+        --set PERL5LIB "${makePerlPath [ perlPackages.CDDB_get ]}" \
+        --set PATH "${toolDeps}"
+    done
+  '';
+
+  meta = {
+    homepage = http://bach.dynet.com/crip/;
+    description = "Terminal-based ripper/encoder/tagger tool for creating Ogg Vorbis/FLAC files";
+    license = stdenv.lib.licenses.gpl1;
+    platforms = stdenv.lib.platforms.linux;
+    maintainers = [ maintainers.endgame ];
+  };
+}
diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix
index 1480b906403..b002534f29e 100644
--- a/pkgs/top-level/all-packages.nix
+++ b/pkgs/top-level/all-packages.nix
@@ -1053,6 +1053,8 @@ with pkgs;
 
   cri-tools = callPackage ../tools/virtualization/cri-tools {};
 
+  crip = callPackage ../applications/audio/crip { };
+
   crunch = callPackage ../tools/security/crunch { };
 
   crudini = callPackage ../tools/misc/crudini { };