2025-07-10 08:00:00 +01:00
|
|
|
{ git, writeShellApplication }:
|
|
|
|
|
|
|
|
writeShellApplication {
|
|
|
|
name = "tag-release";
|
|
|
|
|
|
|
|
runtimeInputs = [ git ];
|
|
|
|
|
|
|
|
text = ''
|
|
|
|
commit_sha="''${1:-HEAD}"
|
2025-09-25 08:00:00 +01:00
|
|
|
tag="$(date '+%Y%m%d%R%S' | sed "s/://g")"
|
2025-07-10 08:00:00 +01:00
|
|
|
|
|
|
|
echo "Tagging commit $(git rev-parse "''${commit_sha}") as ''${tag}."
|
|
|
|
echo ""
|
|
|
|
|
|
|
|
git tag "''${tag}" "''${commit_sha}"
|
|
|
|
'';
|
|
|
|
}
|