Github Branch,Tag: How to get a specific release of a code?
<p>I'm new to Git hub and I got confused about the concept of tag and branch(explained <a href="https://stackoverflow.com/questions/1457103/how-is-a-tag-different-from-a-branch-which-should-i-use-here">here</a>)
I would like to get an stable version of PhantomJS(version 2.1.0) from git hub. But I don't understand if I should do:</p>

<pre><code>git checkout master
git remote add upstream https://github.com/ariya/phantomjs.git
git fetch upstream
git rebase --onto tags/2.1.0 upstream/master master
</code></pre>

<p>or </p>

<pre><code>git init
git remote add -t 2.1 -f origin https://github.com/ariya/phantomjs.git
git checkout 2.1
</code></pre>

<p>Would you please explain me which one and why?</p>