It happens to me all the time. I accidentally version a file, I do not want to be versioned (i.e. developer/machine specific config-files).
If I commit this file, I
It sounds like you have already added and committed the file to subversion (I assume that you are using Subversion). If that is the case, then there are only two ways to remove that file:
svnadmin dump
, filter out the revision where you accidentally committed the file and perform an svnadmin load
.Trust me, you don't really want to do number 2. It will invalidate all working copies of the repository. The best is to do number 1, mark the file as ignored and apologise.