dotnet / dotnet/project-system
Marking generated files as locked/read only
Open
Triage-Investigate
- Dominant language
- C#
- Stars
- 1k
- Forks
- 415
- PR merge metrics
- No merged PRs in 30d
Description
Following a pattern similar to [what's described here](https://mhut.ch/journal/2015/06/30/build-time-code-generation-in-msbuild), I'm generating some c# files into the intermediate output directory. When those files are opened in the editor, the user can edit them. Is it possible for me to mark those C# files in a way that causes them to be read only? Similar to NuGet `contentFiles` or C# files generated via a C# 9 Source Generator?
Contributor guide
Assessment
This issue has not been assessed yet.