title: Routinely sync a branch to master using git rebase
body: <p>I have a Git repository with a branch that hardly ever changes (nobody else is contributing to it). It is basically the master branch with some code and files stripped out. Having this branch around makes it easy for me to package up a leaner version of my project without having to strip out the code and files manually every time.</p>
  
  <p>I have been using <code>git rebase</code> to keep this branch up to date with the master but I always get this warning when I try to push the branch after rebasing:</p>
  
  <pre><code>To prevent you from losing history, non-fast-forward updates were rejected
  Merge the remote changes before pushing again.  See the 'Note about
  fast-forwards' section of 'git push --help' for details.
  </code></pre>
  
  <p>I then use <code>git push --force</code> and it works but I feel like this is probably bad practice. I want to keep this branch "in sync" with the master quickly and easily. Is there a better way of handling this task? </p>
  
  <h3>Update</h3>
  
  <p>See this topic for a full explanation and solution:</p>
  
  <p><a href="https://stackoverflow.com/questions/559917/git-rebase-and-git-push-non-fast-forward-why-use">git rebase and git push: non-fast forward, why use?</a></p>