dmaz99 dmaz99 - 22 days ago 17
Git Question

View order a list of git commits

I have a list of commit hashes and I need to order them chronologically.

I thought I could get

git rev-list
to do it, but it insists on showing me all the commits even if I specify a commit on the command line.

Is there a way to make git do this or do I have to combine
git rev-list
and
grep
?

Thanks!

Answer

Use the --no-walk option. It works on everything based off git rev-list.

Comments