title: How to create the branch from specific commit in different branch
body: <p>I have made several commits in the master branch and then merged them to dev branch.</p>
  
  <p>I want to create a branch from a specific commit in dev branch, which was first committed in master branch.</p>
  
  <p>I used the commands:</p>
  
  <pre><code>git checkout dev
  git branch  &lt;branch name&gt; &lt;commit id&gt;
  </code></pre>
  
  <p>However, this creates the branch from master branch, not the dev branch I expected. The commit id is same in master branch and dev branch.
  So, how can I distinguish same commit id in different branch?</p>
  
  <p>PS: I made an example in github here <a href="https://github.com/RolandXu/test_for_branch" rel="noreferrer">https://github.com/RolandXu/test_for_branch</a></p>
  
  <p>I used the commands:</p>
  
  <pre><code>git checkout dev
  git branch test 07aeec983bfc17c25f0b0a7c1d47da8e35df7af8
  </code></pre>
  
  <p>What I expect is that the test branch contains aa.txt bb.txt cc.txt. However, the test branch only contains aa.txt and cc.txt. It most likely created the branch from the master branch.</p>