title: git - Is it possible to exclude file from `git push`, but keep them in the local repository?
body: <p>In my home directory I have files in a local git repository, because I want track them all under version control.</p>
  
  <p>Most of these files I want to push to a remote repository, but a few I want to keep <em>in my local repository only</em> (they contain mildly sensitive information). </p>
  
  <p>How can I achieve this with git? Can I configure a "<code>.gitignore-for-push</code>" file? I cannot use the local <code>.gitignore</code> file, because it would exclude these files completely from being tracked. </p>
  
  <p>ps: I am aware of question <a href="https://stackoverflow.com/questions/4293536/is-there-an-exclude-file-equivalent-for-pushing-in-git">Is there an exclude file-equivalent...</a>, but the answer goes down the <code>.gitignore</code> path which I cannot use. The other question <a href="https://stackoverflow.com/questions/2479162/exclude-specific-files-when-pushing-to-a-specific-git-repository">Exclude specific files when pushing...</a> answers only a specific case for git+heroku, not git alone.</p>