Search code examples
asp.net-mvcgitvisual-studiogithubgit-clone

Why ApplicationInsights.config file was ignored automatically from being added to Github Repository


I created a asp.net mvc project in VisualStudio and published it in Github. I noticed that the ApplicationInsights.config file was ignored by default.

Now the project can not be compiled when cloned due to this file is missing. After that I added it manually to the repo and everything worked as expected.

Why was this file ignored by default? Is it a bad practice to add this file to the repository?


Solution

  • I believe it was because someone thought that there are secrets in this file based on discussion like this one:

    https://github.com/github/gitignore/pull/1815