From 950daf7fc384606605cafca1617bf12676485bed Mon Sep 17 00:00:00 2001 From: ยท๐‘‘๐‘ด๐‘•๐‘‘๐‘ฉ๐‘ค Date: Tue, 23 Dec 2025 06:22:23 +0000 Subject: mark-darcs-weak-hash: move to Nix --- nix/package/mark-darcs-weak-hash.nix | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 nix/package/mark-darcs-weak-hash.nix (limited to 'nix/package/mark-darcs-weak-hash.nix') diff --git a/nix/package/mark-darcs-weak-hash.nix b/nix/package/mark-darcs-weak-hash.nix new file mode 100644 index 0000000..7f644e1 --- /dev/null +++ b/nix/package/mark-darcs-weak-hash.nix @@ -0,0 +1,26 @@ +#โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” +# SPDX-FileCopyrightText: 2025 toastal โ”‚ +# SPDX-License-Identifier: LGPL-2.1-or-later โ”‚ +#โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ +{ + lib, + writeDashBinScript, + darcs, + gawk, +}: + +let + path = lib.makeBinPath [ + darcs + gawk + ]; +in +writeDashBinScript { + name = "mark-darcs-weak-hash"; + text = /* sh */ '' + export PATH="${path}:$PATH" + + darcs show repo \ + | awk '/^[[:space:]]*Weak Hash:/ { sub(/^[[:space:]]*Weak Hash:[[:space:]]*/, "", $0); printf $0 }' > "$PWD/_darcs/weak_hash" + ''; +} -- cgit v1.2.3