-
Notifications
You must be signed in to change notification settings - Fork 84
Make output more human-readable #200
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
Conversation
If using absorb.fixupTargetAlwaysSHA, the original commit hash will be shown instead.
|
In #126 (comment) @tummychow had comments:
done
dropped log level throughout, but kept log-associated color for the "message". Happy to take another tack
printing in human friendly format. Happy to drop. (While I'm here, I'm not sure "header" makes much sense to humans; is there interest in renaming to "changes" or something like that?) sample output from before this change: and after: and a sample with warnings: |
|
Thx for those screenshots. @blairconrad Mind to include both short hashes? For the change header, you may consider just a short version |
I've neither desire nor objection. I'm just a guy trying to burn through the backlog. Will wait on @tummychow's overall opinion on the change.
#126 specifically mentioned changing the +1,-2 format to "1 insertion(+), 2 deletions(-)"; it matches git, and you can see from the PR that it was an intentional change. I even quoted tummychow's comment about it ealier:
|
|
While we're talking about the format and have examples, here's my unsolicited take.
We'd then have (optionally with the short hash of the new commit in "target", although that would probably mess with the structured logging that @tummychow likes; maybe there's an opportunity customize the logging format to accommodate this style of message, but it would have to work with all the flavours of log messages that git-absorb emits...) |
| announce(logger, Announcement::Committed(&head_commit, &diff)); | ||
| announce( | ||
| logger, | ||
| Announcement::Committed(&head_commit, dest_commit_locator, &diff), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The output may look funny if people use an overly-long commit summary. We could truncate in case it's long or just say "well, they asked for it..."
|
That suggestion works for me, although I'd appreciate the fixed commit's hash too. But as long as we at least get the subject it's already a great improvement. ACK either way. Edit: missed those extra comments. Both short change format and long-form are fine, but my preference is with the shorter one. |
Fixes #126. Closes #177.
Relies heavily on @arielf212's #177, especially for hash-shortening code.