I am using Git on Ubuntu 10.04 (Lucid Lynx).
I have made some commits to my master.
However, I want to get the difference between these commits. All of them are on my master branch.
For example:
commit dj374
made changes
commit y4746
made changes
commit k73ud
made changes
I want to get the difference between k73ud and dj374. However, when I did the following I couldn’t see the changes I made in k73ud.
git diff k73ud..dj374 > master.patch
Try
to make sure to include all changes of
k73udin the resulting diff.git diffcompares two endpoints (instead of a commit range).Since the OP wants to see the changes introduced by
k73ud, they need to differentiate between the first parent commit ofk73ud:k73ud^(ork73ud^1ork73ud~).That way, the
diffresults will include changes sincek73udparent (meaning including changes fromk73uditself), instead of changes introduced sincek73ud(up todj374).Also you can try:
and (1 space, not more):
And if you need to get only files names (e.g. to copy hotfix them manually):
And you can get changes applied to another branch: