-
Notifications
You must be signed in to change notification settings - Fork 793
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Folder name must be unique in the entire project #246
Comments
btw this check is there to prevent something like this: <ItemGroup>
<Compile Include="A\B\File.fs" />
<Compile Include="C\File.fs" />
<Compile Include="A\File.fs" />
</ItemGroup> where folder |
This is happening now in a Xamarin Android project. It's impossible to work with F# here, because of the requirement to have resources with multiple resolutions. |
Visual Studio 2017, V15.6.7 |
The fix in my case was to put the resource includes above the other files, rather than below. I had copied and pasted a bunch of images into the solution, and the resulting fsproj file looked like this:
Changing it to this fixed the issue:
|
Thanks @SpiegelSoft |
This is not fixed. It needs to be reopened. |
The fix I posted earlier does not work for my current project. |
Thanks Philip. What I have found is this. File order is crucial. If you have more than one file, the ordering needs to be as follows:
Any deviation from this ordering will reintroduce the problem. |
@SpiegelSoft I don't quite recall how Android Studio lays Android resources out on disk, but I vaguely recall a similar ordering. Do the Android Xamarin tools not order in the manner by default? |
Not using right click with copy and paste. |
This is with Visual Studio 2017 |
The .NET SDK-style project system fully supports these scenarios: <Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>netcoreapp2.2</TargetFramework>
</PropertyGroup>
<ItemGroup>
<Compile Include="First\First\File.fs" />
<Compile Include="First\Second\File.fs" />
<Compile Include="Second\File.fs" />
<Compile Include="Program.fs" />
</ItemGroup>
</Project> We're frozen the legacy project system, so I'll close this. Moving code to the .NET SDK project system will resolve any issues of this nature. |
When multiple folders with the same name ( but different path ) exist in the project, the following error occurs:
ref:
an example (see )
instead this is ok:
also invalid:
i got a pr to fix this behaviour
The text was updated successfully, but these errors were encountered: