Unity Error: “Class defined in script does not match file name” happens after pushing to version control

Sometimes when I push my Unity scripts, scenes, proj, etc… to version control main repository and I open my project again, I get this error “The class defined in script file name ‘file’ does not match the file name!” even though it does and has been working previously. Sometimes this goes away when I close and open the project again or reset my computer. But this an absurd solution to getting this fixed.

Why does this keep happening and how do I prevent it in the future?

I am using Kiln for version control and C# for language.

Did you set up your project for generating .meta files? Unity requires it!
See this http://docs.unity3d.com/Documentation/Manual/ExternalVersionControlSystemSupport.html