Closed mooski closed 3 years ago
Hi Mark, thanks for the detailed steps!
I was able to replicate this issue, even without LibSassBuilder
, as it seems related to this VS issue.
Replicate by just having this in the .csproj
and add a new .scss
file:
<ItemGroup>
<FooFile Include="**/*.scss" />
</ItemGroup>
By tracking the files in ItemGroup
- VS just adds these extra elements for some reason:
VS is trying to avoid double-including the same file. The Microsoft.Net.Sdk has a None "glob" that includes everything under the project root that isn't a Compile or EmbeddedResource. Opt out of that by setting EnableDefaultNoneItems property to false.
Unfortunately those suggestions didn't work for me. @JelleHissink do you have any thoughts on this?
Hi, I noticed the same, googled... found a fix, did not yet have time to implement it. Will make this a prio.... I might have some time this evening.
Regards, Jelle
I found some time during my lunch break...
Awesome thanks @JelleHissink !
This fix is available in v1.6.2
Thanks @johan-v-r and @JelleHissink for taking a look so quickly and fixing the issue.
I hadn't realised that this is a Visual Studio issue, but I'm glad that you managed to find a fix for it - MSBuild is something of a mystery to me so there's no way that I've have got to a solution myself!
Thanks again.
Firstly, I just want to say that this is a great tool and it's worked for me where others have failed - so thank you for providing this for us all to use!
I have 2 issues with it which I'm hoping you can help with. I'll describe these separately - the first issue is how SCSS files seem to get excluded by default, and I'm not sure why this is happening or what's causing it. This is happening in a Blazor project of mine, but I've tried in a simple console application too and the same thing happens. This is happening in Visual Studio so I don't know if this is interfering somehow. These are the repro steps:
Visual Studio 2019, version 16.9.0. LibSassBuilder 1.6.1.
This happens every time I add a new SCSS file, which is quite irritating as every time I have to go and manually remove this element from the .csproj file.
I hope you can help me to understand why this is happening.