about summary refs log tree commit diff
path: root/pkgs/by-name
diff options
context:
space:
mode:
authorPeder Bergebakken Sundt <pbsds@hotmail.com>2023-12-15 16:37:11 +0100
committerGitHub <noreply@github.com>2023-12-15 16:37:11 +0100
commit911f11b640bcbbd210fea8e98373a2a27350026b (patch)
treea1d9474014ffce6ef9cef670e7bc6e01426a5dc7 /pkgs/by-name
parent1eeb073bff97af20eaa73a3563d8836fca61b367 (diff)
parent7ac8a22e971ee850111ddc48ab926640200755e3 (diff)
downloadnixlib-911f11b640bcbbd210fea8e98373a2a27350026b.tar
nixlib-911f11b640bcbbd210fea8e98373a2a27350026b.tar.gz
nixlib-911f11b640bcbbd210fea8e98373a2a27350026b.tar.bz2
nixlib-911f11b640bcbbd210fea8e98373a2a27350026b.tar.lz
nixlib-911f11b640bcbbd210fea8e98373a2a27350026b.tar.xz
nixlib-911f11b640bcbbd210fea8e98373a2a27350026b.tar.zst
nixlib-911f11b640bcbbd210fea8e98373a2a27350026b.zip
Merge pull request #271013 from onemoresuza/treecat
treecat: init at 1.0.2-unstable-2023-11-28
Diffstat (limited to 'pkgs/by-name')
-rw-r--r--pkgs/by-name/tr/treecat/package.nix47
1 files changed, 47 insertions, 0 deletions
diff --git a/pkgs/by-name/tr/treecat/package.nix b/pkgs/by-name/tr/treecat/package.nix
new file mode 100644
index 000000000000..df184b9d1062
--- /dev/null
+++ b/pkgs/by-name/tr/treecat/package.nix
@@ -0,0 +1,47 @@
+{ stdenv
+, fetchFromSourcehut
+, hare
+, haredo
+, lib
+, scdoc
+}:
+stdenv.mkDerivation (finalAttrs: {
+  pname = "treecat";
+  version = "1.0.2-unstable-2023-11-28";
+
+  outputs = [ "out" "man" ];
+
+  src = fetchFromSourcehut {
+    owner = "~autumnull";
+    repo = "treecat";
+    rev = "d277aed99eb48eef891b76916a61029989c41d2d";
+    hash = "sha256-4A01MAGkBSSzkyRw4omNbLoX8z+pHfoUO7/6QvEUu70=";
+  };
+
+  nativeBuildInputs = [
+    hare
+    haredo
+    scdoc
+  ];
+
+  dontConfigure = true;
+
+  preBuild = ''
+    HARECACHE="$(mktemp -d)"
+    export HARECACHE
+    export PREFIX="${builtins.placeholder "out"}"
+  '';
+
+  meta = {
+    description = "Serialize a directory to a tree diagram, and vice versa";
+    longDescription = ''
+      Treecat is an amalgamation of `tree(1)` and `cat(1)`, with the added
+      bonus that it can reconstruct its output back into the original filetree.
+    '';
+    homepage = "https://sr.ht/~autumnull/treecat/";
+    license = lib.licenses.wtfpl;
+    maintainers = with lib.maintainers; [ onemoresuza ];
+    mainProgram = "treecat";
+    inherit (hare.meta) platforms badPlatforms;
+  };
+})