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

diff_util: Add the short alias S for --stat #5051

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

PhilipMetzger
Copy link
Contributor

This was a suggestion from sm in the libera #jujutsu IRC chat.

Checklist

If applicable:

  • I have updated CHANGELOG.md
  • I have updated the documentation (README.md, docs/, demos/)
  • I have updated the config schema (cli/src/config-schema.json)
  • I have added tests to cover my changes

@simonmichael
Copy link

More context, in case it helps:

what would you think of adding -S as short flag for --stat (for jj diff, eg)
"like -s, but louder"
the value could be having a discoverable convenient shortcut for all.. if it's not too clashy

I was repeatedly running diff (or log) with successively more detail:

jj diff, jj diff -s, jj diff --stat, jj diff -p
and using terminal history to edit the previous command. The --stat is just a little awkward to type each time. 

Copy link
Member

@martinvonz martinvonz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are only ~50 possible short flags, so we need to be careful about adding new ones. I don't think we've heard the request often enough that we should add a flag.

cli/src/diff_util.rs Outdated Show resolved Hide resolved
@PhilipMetzger
Copy link
Contributor Author

There are only ~50 possible short flags, so we need to be care. I don't think we've heard the request often enough that we should add a flag.

Agreed, so I'll leave it up for @simonmichael until we hear more demand for it,

@simonmichael
Copy link

Waiting to see if this is worthwhile is quite understandable.

This was a suggestion from sm in the libera #jujutsu IRC chat.
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.

3 participants