daveaglick / Scripty

Tools to let you use Roslyn-powered C# scripts for code generation
MIT License
620 stars 69 forks source link

Scripty still runs even if file is excluded from project #125

Open naasking opened 6 years ago

naasking commented 6 years ago

Scripty still tries to run the .csx file, even if it's excluded from project.

naasking commented 6 years ago

Note that this may be a VS 2017-specific issue, because I've had similar issues where it tries to build regular .cs files that are excluded from the project file too.

daveaglick commented 6 years ago

Is this one of the new SDK-style project files or an older classic .csproj file?

naasking commented 6 years ago

Brand new project .NET standard project started in VS 2017, but it has a .csproj file. VS 2017 has been very weird so far. For instance, if I exclude the .csx file and the generated .cs file then try to build, it still tries to build the generated .cs file. I have to actually delete the generated file to build properly, so I'm not sure this is Scripty's doing.