In SVN you can use some keyword expansion to put your revision number inside source files. I find this particularly useful on SQL scripts.
Using TFS2010, how can I put the changeset number inside a source file ?
If you really must insert the current changeset number in a file, you can use the Keyword Substitution Check-in Policy.