From 474d732b61673c311b212262fc4fee88430bbced Mon Sep 17 00:00:00 2001 From: Benedikt Peetz Date: Mon, 30 Sep 2024 16:43:29 +0200 Subject: feat(common/init): Perform the first run of `reuse` on init --- common/init | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'common/init') diff --git a/common/init b/common/init index ecb52f4..f8c8bb3 100644 --- a/common/init +++ b/common/init @@ -165,4 +165,18 @@ chmod +x scripts/* chmod +x update.sh [ -f ./build.sh ] && chmod +x build.sh [ -f ./watch.sh ] && chmod +x build.sh + +# Do the first run of reuse annotate +reuse="$(nix build nixpkgs#reuse --no-link --print-out-paths)" +[ "$(echo "$reuse" | wc -l)" -ne 1 ] && die "Something is wrong with the nixpkgs#reuse derivation" + +git add . + +git diff --name-only --cached | + xargs -I {} "$reuse" annotate \ + --copyright "$AUTHOR_NAME <$AUTHOR_EMAIL>" \ + --copyright-style string-c \ + --template default \ + --license "$SPDX_LICENSE_IDENTIFIER" "{}" + # vim: ft=sh -- cgit 1.4.1