git diff notes

From thelinuxwiki
Revision as of 20:58, 10 March 2021 by Nighthawk (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

git basics.jpg


get last two commits for a particular file

$ git log -n 2 <path to file>

diff between to commits

$ diff <commit1> <commit2> <path to file>