about summary refs log tree commit diff stats
path: root/sys/nixpkgs/pkgs/yt/yt.nix
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--sys/nixpkgs/pkgs/yt/yt.nix27
1 files changed, 27 insertions, 0 deletions
diff --git a/sys/nixpkgs/pkgs/yt/yt.nix b/sys/nixpkgs/pkgs/yt/yt.nix
new file mode 100644
index 00000000..184b7820
--- /dev/null
+++ b/sys/nixpkgs/pkgs/yt/yt.nix
@@ -0,0 +1,27 @@
+{
+  lib,
+  rustPlatform,
+  ytcc,
+  yt-dlp,
+  mpv,
+  makeWrapper,
+}:
+rustPlatform.buildRustPackage {
+  pname = "yt";
+  version = "0.1.0";
+
+  src = ./.;
+  cargoHash = "sha256-AlrixMGbBa+VJZDzplQZwFV9Mp3STjCJUD6zV/JmUyA=";
+
+  buildNoDefaultFeatures = true;
+  buildFeatures = ["yt"];
+
+  nativeBuildInputs = [
+    makeWrapper
+  ];
+
+  postInstall = ''
+    wrapProgram $out/bin/yt \
+      --set PATH ${lib.makeBinPath [mpv yt-dlp ytcc]}
+  '';
+}