Reputation: 890
Imagine that I have 2 branches.
In branchA I have files A and B
In branchB I have deleted the file B and added the file C, si I finally have A and C
Which command could I use to know that I have deleted B and created C?
Upvotes: 2
Views: 76
Reputation: 474
git diff --name-status branchA branchB
This will list the files added, deleted, renamed, or modified along with a one letter code showing whether it was added, deleted, renamed, or modified. It should show something like:
D dir1/B
A dir2/C
Where D means deleted and A means added.
Upvotes: 2
Reputation: 1637
To see the abbreviated stats of each commit you can use:
git log --stat -2
Change the number for the number of commits that you want to display. In this case it will show the last two commits. Don't forget to checkout to the branch that you want to check first.
Upvotes: 0