jeffkl / RoslynCodeTaskFactory

An MSBuild CodeTaskFactory that uses Roslyn compiler for cross platform compatibility
MIT License
26 stars 3 forks source link

Generated file Strings.Designer.cs should not be in git #35

Closed binki closed 6 years ago

binki commented 6 years ago

https://github.com/jeffkl/RoslynCodeTaskFactory/blob/afbc509790b2cc8d76cae6bf697262512bdb8b2d/src/RoslynCodeTaskFactory/Properties/Strings.Designer.cs#L2-L8

This should be somehow put in .gitignore and validated that when built MSBuild can autogenerate it.

jeffkl commented 6 years ago

I used the template .gitignore for Visual Studio which does not have an entry for Strings.Designer.cs. I'm assuming there's no harm in having it checked in. Do you have any stronger argument as to why it shouldn't?

binki commented 6 years ago

Sorry, I should have followed up on this earlier. I tried to figure out a way to exclude it and make VS generate it at compile time, but it just doesn’t seem to have support for that right now. The file is autogenerated upon editing the .resources file and there’s not really a clean and supported way to defer generation—especially since the file must exist already when you are editing code so that the code in it can be seen by IntelliSense.

So this is just me wishing for something which VS doesn’t support yet and not an issue with your project. I am closing this issue.