title: Refresh my local git repo to the contents of remote repo
body: <p>I am writing a program that aggregates data on all branches of a repo every week.</p>
  
  <p>The program will check through 15-20 repos. Basically I need to reset my local git repo to be the same exact thing as the remote one. I won't have any local changes. However, if there are changes I will be switching between commits in each branch to generate a report. So the branches will always be on an older commit. Not sure if this will screw up with a subsequent git pull call?</p>
  
  <p>The code does something like this at the moment:</p>
  
  <pre><code>git clone &lt;repo&gt;
  git pull --progress --verbose
  </code></pre>
  
  <p>then gets a list of branches and checks each branch for new commits that week and aggregates a report on them. By the way, is there a way to git pull for all branches at once?</p>
  
  <p>What's the best way to do this?</p>
  
  <p>I started googling and found many things such as git clean, git fetch, git pull (git merge/fetch) etc. </p>
  
  <p>Will git pull work here? Or is it best to delete all files and clone again? I'd rather avoid unnecessary overhead by cloning the same thing several times if git pull will simply grab the latest commits.</p>
  
  <p>Thanks!</p>