mat.services/nix/update-date.nix

11 lines
250 B
Nix
Raw Permalink Normal View History

2022-10-23 16:16:12 +00:00
{ coreutils, sd, writeShellScriptBin }:
writeShellScriptBin "update-date" ''
export VERSION=$1
if [ -z "$VERSION" ]
then
export VERSION=$(${coreutils}/bin/date -I)
fi
${sd}/bin/sd 'version = ".*"' 'version = "'$VERSION'"' flake.nix
''