Skip to content
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

Timestamp format #2106

Merged
merged 12 commits into from
May 29, 2024
Merged

Timestamp format #2106

merged 12 commits into from
May 29, 2024

Conversation

neunenak
Copy link
Contributor

No description provided.

@neunenak
Copy link
Contributor Author

This PR is failing the test config::tests::show_arguments because the clap-generated Usage: string insists on adding --timestamp-format, and I'm not sure why

@casey
Copy link
Owner

casey commented May 29, 2024

.arg("--timestamp-format FORMAT") passes the single arg "--timestamp-format FORMAT", it needs to be .arg("--timestamp-format").arg("FORMAT") or .args(["--timestamp-format", "FORMAT"). I just pushed a commit fixing it.

@neunenak
Copy link
Contributor Author

.arg("--timestamp-format FORMAT") passes the single arg "--timestamp-format FORMAT", it needs to be .arg("--timestamp-format").arg("FORMAT") or .args(["--timestamp-format", "FORMAT"). I just pushed a commit fixing it.

Ah thanks for fixing that

@neunenak neunenak marked this pull request as ready for review May 29, 2024 08:17
@casey casey enabled auto-merge (squash) May 29, 2024 09:26
@casey casey merged commit 77a6e02 into casey:master May 29, 2024
5 checks passed
@casey
Copy link
Owner

casey commented May 29, 2024

  • I changed the flag to --timestamp. I noticed in the examples in the readme, you used --timestamp, which I think would be a common error, and --timestamp is shorter anyways.
  • I removed the --ts alias for now. If it's a commonly used flag, I'd rather just give it a short flag, like -t or -T.
  • TIMESTAMP_FORMAT has a default value, so it can just be unwrapped.

@casey
Copy link
Owner

casey commented May 29, 2024

Oh yeah, also made it local time, since I figure that's more useful, and if it's local time, they can at least configure it by changing the time zone of their system, whereas if it's UTC, they can't configure it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants