nixpkgs-suyu/pkgs/tools/video/lux/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

45 lines
987 B
Nix
Raw Permalink Normal View History

2023-10-30 10:21:54 +01:00
{ lib
, buildGoModule
, fetchFromGitHub
, makeWrapper
, ffmpeg
}:
2022-09-24 03:42:43 +02:00
buildGoModule rec {
pname = "lux";
2024-02-21 08:17:08 +01:00
version = "0.23.0";
2023-10-30 10:21:54 +01:00
2022-09-24 03:42:43 +02:00
src = fetchFromGitHub {
owner = "iawia002";
repo = "lux";
rev = "v${version}";
2024-02-21 08:17:08 +01:00
hash = "sha256-lZrsrBO3sAn4wAMMgxrVwky7HmKxnQQcLe1POYTAmoE=";
2022-09-24 03:42:43 +02:00
};
nativeBuildInputs = [ makeWrapper ];
2023-11-25 01:44:18 +01:00
vendorHash = "sha256-1VZFKDoSuSUmYw7g6SwB/dXnFaw7+cGHKfgT96HaI/o=";
2022-09-24 03:42:43 +02:00
2023-10-30 10:21:54 +01:00
ldflags = [
"-s"
"-w"
"-X github.com/iawia002/lux/app.version=v${version}"
];
2022-09-24 03:42:43 +02:00
postInstall = ''
wrapProgram $out/bin/lux \
--prefix PATH : ${lib.makeBinPath [ ffmpeg ]}
'';
2023-10-30 10:21:54 +01:00
doCheck = false; # require network
2022-09-24 03:42:43 +02:00
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;
2023-10-30 10:21:54 +01:00
maintainers = with maintainers; [ galaxy ];
2023-11-23 03:51:17 +01:00
mainProgram = "lux";
2022-09-24 03:42:43 +02:00
};
}