Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8368667
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T13:26:30+00:00 2026-06-09T13:26:30+00:00

git shortlog is handy for making a human-readable summary of changes. However, when I

  • 0

git shortlog is handy for making a human-readable summary of changes. However, when I cherry-pick changes from the master branch I use the -x flag to git cherry-pick because it records which commit it picked from. This causes some ugliness in the shortlog:

% git shortlog Version-3.5.3..3.5

Dan S (5):
  Fix typo that causes build fail on big-endian archs, thanks Felipe Sateler     (cherry picked from commit 4588258193072cd2fb845f7fb0b4670d6ad5edf2)
  fix build on ARM (where qreal==float); thanks Felipe Sateler     (cherry picked from commit 976d560060185c1e31c9f40660172f0054a4a05c)
  Strip gremlin characters from JITLib wrapForNodeProxy.sc     (cherry picked from commit d0842acae77a90b5eb9811d947ee2dad2282edff)
  choose clipping rather than wraparound for writing integer-format audio     files (libsndfile setting)
  arm build fix: another double->qreal in QcMultiSlider     (cherry picked from commit 548ad319dddf53e4edac1cfa44b3193027eefda2)

Is there an easy way to tell git shortlog that we don’t want those cherry-pick lines (which are on new lines in the actual log)?

Of course, I know it’s possible to filter them out, for example using git shortlog Version-3.5.3..3.5 | sed 's/[(]cherry picked.*$//g'. But it seems that git should be aware of its own annotations and be able to deal with them. Anything I’ve missed?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T13:26:32+00:00Added an answer on June 9, 2026 at 1:26 pm

    Is there an easy way to tell git shortlog that we don’t want those
    cherry-pick lines (which are on new lines in the actual log)?

    Currently, there is no easy way to do it with git shortlog alone.

    These cherry-pick lines are added on the second lines of the commit message, so they are considered a part of the commit title by most of the git tools. As Vince suggested, one can try to provide a custom format for shortlog entries (with --format option), however, there seems to be no such pretty-formats or format placeholders that would return only the first line of the subject. (see man git log)

    But it seems that git should be aware of its own annotations and be
    able to deal with them. Anything I’ve missed?

    git shortlog actually seems to be aware only of [PATCH] prefixes (precisely, in terms of regexp: ^\s*\[PATCH[^]]*\]).

    To sum up, I think that the best would be to stay with your sed substitution.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

git status # On branch master # Changed but not updated: # (use git
git pull --help Incorporates changes from a remote repository into the current branch. I
git status tells me that my branch and the one I started from on
git-cherry lets me find all the commits missing from upstream. How do I find
git clone git@github.com:foo/bar.git bar-master git branch release git push origin release git clone -b
$ git branch master * portal $ git fetch $ git merge origin/portal Already
git show shows me all the changes made in a revision. However, it prints
for projects under git controls, I use git shortlog to get counts of commits.
git version 1.7.3.5 I have the following branches: git branch image master * video
git version 1.7.5.4 I have about 5 branches. All from the same initial branch.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.