about summary refs log tree commit diff
path: root/pkgs/tools/video
diff options
context:
space:
mode:
authorCandy Cloud <candyc1oud@outlook.com>2022-09-24 01:42:43 +0000
committerCandy Cloud <candyc1oud@outlook.com>2022-09-24 01:42:43 +0000
commit4bdd6b834d7a4a07a5a921c8e0539b95ce805533 (patch)
tree9eb673e62245cd58021205f062ed55fd9b4ea77f /pkgs/tools/video
parenta291f1dc264d3492cbfb9dbb8955955bc2daad96 (diff)
lux: init at 0.15.0
Diffstat (limited to 'pkgs/tools/video')
-rw-r--r--pkgs/tools/video/lux/default.nix33
1 files changed, 33 insertions, 0 deletions
diff --git a/pkgs/tools/video/lux/default.nix b/pkgs/tools/video/lux/default.nix
new file mode 100644
index 0000000000000..520ab6b42a2c2
--- /dev/null
+++ b/pkgs/tools/video/lux/default.nix
@@ -0,0 +1,33 @@
+{ lib, buildGoModule, fetchFromGitHub, makeWrapper, ffmpeg }:
+
+buildGoModule rec {
+  pname = "lux";
+  version = "0.15.0";
+  src = fetchFromGitHub {
+    owner = "iawia002";
+    repo = "lux";
+    rev = "v${version}";
+    sha256 = "sha256-fZR+Q0duITZq3Ynr2WTZAhDnmEkXrT2gXUlpuN0+aFo=";
+  };
+
+  nativeBuildInputs = [ makeWrapper ];
+
+  vendorSha256 = "sha256-SHUtyfGRGriEaESo6th7gGQn6V4REdk3XT0ZlGwky7E=";
+
+  ldflags = [ "-s" "-w" ];
+
+  postInstall = ''
+    wrapProgram $out/bin/lux \
+      --prefix PATH : ${lib.makeBinPath [ ffmpeg ]}
+  '';
+
+  doCheck = false;
+
+  meta = with lib; {
+    description = "Fast and simple video download library and CLI tool written in Go";
+    homepage = "https://github.com/iawia002/lux";
+    changelog = "https://github.com/iawia002/lux/releases/tag/v${version}";
+    license = licenses.mit;
+    maintainers = with maintainers; [ candyc1oud ];
+  };
+}