title: See git diff without checking out a branch?
body: <p>Basically I have a deployed app that I <em>believe</em> is up to date with the git repo, but I am not sure. I ran <code>git init</code> in the project root, and set the correct origin. I tested the connection and I am able to connect to the repo and get a list of branches by running <code>git ls-remote --heads git@myurl.git</code>. My question now is, is there a way to use <code>git diff</code> to see if the deployed app is in sync with a certain branch without checking out master? What exactly would git do if I ran <code>git checkout master</code>?</p>
  
  <p><strong>EDIT:</strong></p>
  
  <p>The problem is that the deployed app has never been tracked by git directly, it was tracked on my local machine and I would push updates by generating a tarball of all the changed files with a python gif diff script that I untar at the root of the deployed app directory. Today I set up a deploy key in gitlab so that I could just run <code>git pull</code> on the deployed app. I guess a better question would be, what's the best way to get that going? It's been a while since that app has been touched and I don't know if another developer has gone in and made untracked changes, I don't want to lose any changes that have been made to the deployed app, so I was hoping there was a way to see the difference between master and the deployed app.</p>