Skip to content

🚀 Configurable timestamp output format in git blame #1157

@mliszcz

Description

@mliszcz

In git blame I noticed this:
image

It would be helpful to know e.g. which change was applied first but this can not be figured out from the humanized timestamp.

chrono_humanize::HumanTime::from(blame.time).to_string(),

I changed it locally to: blame.time.format("%H:%M %Y-%m-%d").to_string(),.

Would it be possible to make this configurable? Perhaps a new option --blame-output-timestamp-format could be added. If present (and not empty) it would be used as a format string. If not, we will fall back to HumanTime formatting. What do you think?

I can work on a PR if this could be accepted.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions