I would like to know if there is a way to get cumulative git diff for several non-sequential commits.
As an example, I can get what was changed in each commit using:
git diff 123456^ 123456
Where "123456" is the git hash.
I can use this for several commits. But now I want to make several differences and combine the output into one.
As an example,
git diff 123456^ 123456 git diff abcdef^ abcdef
But combine diff into one. But "123456" and "abcdef" are not consecutive commits.
Update: Let's say the line in the xyz file has changed:
In commit 123456: from "foo" to "bar" in commit abcdef: from "bar" to "oof"
I just want to see him change from "foo" to "oof" after that to commit.
git diff 123456 abcdef does not work for me because I don't want all the changes between 123456 and abcdef.
I do not want to do anything; just want this to view the code for security.
source share