-
Notifications
You must be signed in to change notification settings - Fork 788
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make .CreatedAt and other timestamps time.Time types #1266
Comments
This is a good idea. |
@KenYN I'm hesitant to change the format of the timestamp as it is now. But I'd be OK with adding a new field for them, basically appending "Raw" to it, so you can do:
I'm going to assume this would be useful and will get a PR together for the image side of things anyway and we can then move on to containers and Podman. |
TomSweeneyRedHat
added a commit
to TomSweeneyRedHat/buildah
that referenced
this issue
Jan 9, 2019
Signed-off-by: TomSweeneyRedHat <[email protected]> This adds the ability to see a "raw" date format for the CreatedAt field rather than the pretty formatted variety. Wit this in place the files will print thusly: .CreatedAt: "Jan 8, 2019 09:22" .CreatedAtRaw: "2019-01-08 09:22:52.330623532 -0500 EST" This hopefully at least partially addresses containers#1266 Once agreed to, we might want to do a similar thing for buildah containers and then in similar commands in Podman.
rh-atomic-bot
pushed a commit
that referenced
this issue
Jan 9, 2019
Signed-off-by: TomSweeneyRedHat <[email protected]> This adds the ability to see a "raw" date format for the CreatedAt field rather than the pretty formatted variety. Wit this in place the files will print thusly: .CreatedAt: "Jan 8, 2019 09:22" .CreatedAtRaw: "2019-01-08 09:22:52.330623532 -0500 EST" This hopefully at least partially addresses #1266 Once agreed to, we might want to do a similar thing for buildah containers and then in similar commands in Podman. Closes: #1269 Approved by: rhatdan
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
I recently posted this question to StackOverflow about formatting timestamp output from:
But I was informed that
.CreatedAt
is astring
, so I was out of luck. The string is also not localised and is missing timezone information, so even as it is it is not terribly useful. The recommendation given was to request an extraCreatedAtTime time.Time
field that would allow users to format however they needed. (Specifically, I want to add a check to mybuildah
scripts to skip processing if the script is older than the image)This is my contribution to the call for discussion in #537 (comment).
The text was updated successfully, but these errors were encountered: