git show

git show命令用于查看commit的内容

  1. # 输出某次提交的元数据和内容变化
  2. $ git show [commit]
  3. $ git show 12a86bc38 # By revision
  4. $ git show v1.0.1 # By tag
  5. $ git show feature132 # By branch name
  6. $ git show 12a86bc38^ # Parent of a commit
  7. $ git show 12a86bc38~2 # Grandparent of a commit
  8. $ git show feature132@{yesterday} # Time relative
  9. $ git show feature132@{2.hours.ago} # Time relative