diff options
author | zaldnoay <zaldnoay@users.noreply.github.com> | 2023-08-28 22:58:54 +0800 |
---|---|---|
committer | zaldnoay <zaldnoay@users.noreply.github.com> | 2023-08-28 22:58:54 +0800 |
commit | 553f5ac2c8a52e98767847cccc70f9bd2d2b214c (patch) | |
tree | 0b640aae96409624f687fbaead23e7a059284d8c /pkgs/servers/bililiverecorder/default.nix | |
parent | be3cdca0ec19bf7fbb186bd951fba08d81aca324 (diff) |
bililiverecorder: init at 2.6.3
Diffstat (limited to 'pkgs/servers/bililiverecorder/default.nix')
-rw-r--r-- | pkgs/servers/bililiverecorder/default.nix | 51 |
1 files changed, 51 insertions, 0 deletions
diff --git a/pkgs/servers/bililiverecorder/default.nix b/pkgs/servers/bililiverecorder/default.nix new file mode 100644 index 0000000000000..d5094bfb1a6a2 --- /dev/null +++ b/pkgs/servers/bililiverecorder/default.nix @@ -0,0 +1,51 @@ +{ lib +, stdenv +, fetchzip +, makeWrapper +, dotnetCorePackages +}: + +let + pname = "bililiverecorder"; + + dotnet = with dotnetCorePackages; combinePackages [ + runtime_6_0 + aspnetcore_6_0 + ]; + + version = "2.6.3"; + hash = "sha256-h7nsbi831HB1tmo7d9vlR8fSKeTn2Ezn8NVl02Z1oQ0="; + +in +stdenv.mkDerivation { + inherit pname version; + + src = fetchzip { + url = "https://github.com/BililiveRecorder/BililiveRecorder/releases/download/v${version}/BililiveRecorder-CLI-any.zip"; + stripRoot = false; + inherit hash; + }; + + nativeBuildInputs = [ makeWrapper ]; + + installPhase = '' + runHook preInstall + + mkdir -p $out/{bin,share/${pname}-${version}} + cp -r * $out/share/${pname}-${version}/. + + makeWrapper "${dotnet}/bin/dotnet" $out/bin/BililiveRecorder \ + --add-flags "$out/share/${pname}-${version}/BililiveRecorder.Cli.dll" + + runHook postInstall + ''; + + meta = with lib; { + description = "A convenient free open source bilibili live recording tool"; + homepage = "https://rec.danmuji.org/"; + changelog = "https://github.com/BililiveRecorder/BililiveRecorder/releases/tag/${version}"; + license = licenses.gpl3Only; + maintainers = with maintainers; [ zaldnoay ]; + platforms = platforms.unix; + }; +} |