From a07be232df325899ad1da108c8d911ca70e2245e Mon Sep 17 00:00:00 2001 From: Michael Cho Date: Tue, 27 Aug 2024 09:27:47 -0400 Subject: [PATCH] dev-cmd/bottle: use iso8601 for compliance with spec --- Library/Homebrew/dev-cmd/bottle.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Library/Homebrew/dev-cmd/bottle.rb b/Library/Homebrew/dev-cmd/bottle.rb index d5fc7ceba4..e22c77a3d9 100644 --- a/Library/Homebrew/dev-cmd/bottle.rb +++ b/Library/Homebrew/dev-cmd/bottle.rb @@ -685,7 +685,9 @@ module Homebrew "root_url" => bottle.root_url, "cellar" => bottle_cellar.to_s, "rebuild" => bottle.rebuild, - "date" => Pathname(filename.to_s).mtime.strftime("%F"), + # date is used for org.opencontainers.image.created which is an RFC 3339 date-time. + # Time#iso8601 produces an XML Schema date-time that meets RFC 3339 ABNF. + "date" => Pathname(filename.to_s).mtime.utc.iso8601, "tags" => { bottle_tag.to_s => { "filename" => filename.url_encode,