Different IDEs create different project files. Now the question is:
Which project files should I check into my VCS and which not?
This is what this article is about.
Just a few notes before we start:
- Expressions like
bin/
(note the trailing slash) represent directories -
The names of directories holding the compiled sources can be renamed in most IDEs. I’ll list only the default directories.
Visual Studio 2010 ∞
Files to add:
*.sln
*.vcxproj
,*.csproj
*.vcxproj.filters
(C/C++ projects)-
Properties/
(.NET projects)
Files to ignore:
*.user
(including*.vcxproj.user
)*.sdf
*.opensdf
ipch/
Debug/
andRelease/
-
bin/
andobj/
(.NET projects)
Eclipse ∞
Files to add:
.project
.classpath
.settings/
-
*.launch
(shared launch configurations)
Files to ignore:
-
bin/
(default output directory), or*.class
IntelliJ, PyCharm, PhpStorm, WebStorm ∞
Files to add:
-
.idea/
(except forworkspace.xml
)
Files to ignore:
-
.idea/workspace.xml
(Source)
Combined .hgignore file ∞
This section contains the contents for a .hgignore
file that ignores all of the files mentioned above.
syntax: glob # Visual Studio *.user *.sdf *.opensdf **/ipch/ **/Debug/ **/Release/ **/bin/ **/obj/ # Eclipse **/bin/ *.class # JetBrains IDEs **/.idea/workspace.xml
Thanks very much…very useful. I would add this suffix to ignore for DevStudio files:
*.suo
My reasoning is based on this forum discussion.
Thanks, this post was very helpful.