difference between base_sha and sha parameter #1086
-
As per the documentation there are two parameters when seem to govern what is the "from sha" and "to sha" for which the changed file list has to be taken. I am unable to understand the differences between the two. Can you kindly explain with example? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
@kishaningithub The The
A diff is performed using the common ancestor of both branches i.e the point at which both branches diverge. See: https://git-scm.com/docs/git-diff#_examples for more examples |
Beta Was this translation helpful? Give feedback.
@kishaningithub The
base_sha
would be the starting point for the comparison i.e "from sha" which is represented in the image above as"master"
which can either be denoted by the branch name or the commit SHA.The
sha
on the other hand is the endpoint for the comparison i.e "to sha" which is represented in the image above as"dev"
which can either be denoted by the branch name or the commit SHA.A diff is performed using the common ancestor of both branches i.e the point at which both branches diverge.
See: https://git-scm.com/docs/git-diff#_examples for more examples