When you use any IDE to develop an application, they usually generate an additional set of files where they save the project settings. It is considered bad practice to upload these settings to a version control tool such as git, svn, etc, because these configurations are specific to the development environment of each developer, in some cases it can prevent the project from opening properly in the IDE, because it tries to look for resources that are not on your PC, for this reason it is advisable not to upload these configurations.
How to avoid to upload the IDE's configurations?
Git
gives us the .gitignore
file, where we can set all files that we want to ignore. Just create the .gitignore
file in your main project folder, for example ~/workspace/my-project/
, open that file with any text editor (even within your IDE) and add the files to be ignored.
As @Michael says, you can generate a set of files to ignore in base of IDE that you are using, take a look at this link, for example for eclipse (click here to generate) copy and paste the configuration within your .gitignore
file.
If you have already uploaded these configurations to your repository, you must delete them so that the new gitignore configuration takes effect, check out these links revert changes in git, remove files from git