mirror of
https://forge.katzen.cafe/schrottkatze/nix-configs.git
synced 2025-12-22 14:37:13 +01:00
78 lines
1.7 KiB
Diff
78 lines
1.7 KiB
Diff
From 491ad6f41d9335bad450e8be18c2ee24ac5f4e32 Mon Sep 17 00:00:00 2001
|
|
From: TudbuT <forge-public@mail.tudbut.de>
|
|
Date: Mon, 8 Dec 2025 21:24:18 +0100
|
|
Subject: [PATCH] add edname
|
|
|
|
---
|
|
common.nix | 2 ++
|
|
programs/edname.nix | 45 +++++++++++++++++++++++++++++++++++++++++++++
|
|
2 files changed, 47 insertions(+)
|
|
create mode 100644 programs/edname.nix
|
|
|
|
diff --git a/common.nix b/common.nix
|
|
index d64c4d4..3f23075 100644
|
|
--- a/common.nix
|
|
+++ b/common.nix
|
|
@@ -71,6 +71,8 @@ with builtins;
|
|
ungoogled-chromium
|
|
scc
|
|
speedtest-rs
|
|
+
|
|
+ (pkgs.callPackage ./programs/edname.nix {})
|
|
];
|
|
};
|
|
|
|
diff --git a/programs/edname.nix b/programs/edname.nix
|
|
new file mode 100644
|
|
index 0000000..0ba5b21
|
|
--- /dev/null
|
|
+++ b/programs/edname.nix
|
|
@@ -0,0 +1,45 @@
|
|
+{
|
|
+ stdenv,
|
|
+ coreutils,
|
|
+ findutils,
|
|
+ gnused,
|
|
+ lib,
|
|
+ fetchFromGitea,
|
|
+ makeWrapper,
|
|
+}:
|
|
+stdenv.mkDerivation rec {
|
|
+
|
|
+ pname = "edname";
|
|
+ version = "1.0.2";
|
|
+
|
|
+ nativeBuildInputs = [ makeWrapper ];
|
|
+
|
|
+ src = fetchFromGitea {
|
|
+ domain = "git.tudbut.de";
|
|
+ owner = "TudbuT";
|
|
+ repo = "edname";
|
|
+ rev = "v${version}";
|
|
+ hash = "sha256-8aT/xwdx/ORyCFfOu4LZuxUiErZ9ZiCdhJ/WKAiQwe0=";
|
|
+ };
|
|
+
|
|
+ installPhase = ''
|
|
+ mkdir -p $out/bin
|
|
+ cp edname.sh "$out/bin/edname"
|
|
+ wrapProgram "$out/bin/edname" \
|
|
+ --prefix PATH : "${
|
|
+ lib.makeBinPath [
|
|
+ coreutils
|
|
+ findutils
|
|
+ gnused
|
|
+ ]
|
|
+ }"
|
|
+ '';
|
|
+
|
|
+ meta = with lib; {
|
|
+ description = "Mass renamer using $EDITOR";
|
|
+ license = licenses.mit;
|
|
+ maintainers = [ maintainers.tudbut ];
|
|
+ homepage = "https://git.tudbut.de/TudbuT/edname";
|
|
+ mainProgram = "edname";
|
|
+ };
|
|
+}
|
|
--
|
|
2.51.2
|
|
|