title: How to create a local branch from an existing remote branch?
body: <p>I want to create a branch from an existing remote branch (let's say remote-A) and then commit the changes to the repository.</p>
  
  <p>I have used the below commands to create a local branch from the existing remote-A</p>
  
  <pre><code>$git checkout remote-A
  
  git branch
  master
  * remote-A
  </code></pre>
  
  <p>Now I have created local-B from Remote A using the below commands</p>
  
  <pre><code>git branch local-B
  git checkout local-B
  </code></pre>
  
  <p>How do I make sure the changes I have on local-B are on top of remote-A so that when I push local-B to the remote repo, the changes are on top of remote-A?</p>