Skip to content
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

Property Definitions: Placed before FSharp Targets #1585

Closed
ascjones opened this issue Apr 8, 2016 · 5 comments
Closed

Property Definitions: Placed before FSharp Targets #1585

ascjones opened this issue Apr 8, 2016 · 5 comments
Labels

Comments

@ascjones
Copy link
Contributor

ascjones commented Apr 8, 2016

Description

After paket install, Websharper targets are moved up above FSharp target import which they depend on, since this commit: 8a9ba04

Guess we need something similar to this fix for CSharp targets: de12ae8

Repro steps

Import FSharp targets like so:

 <!-- F# targets -->
  <Choose>
    <When Condition="'$(VisualStudioVersion)' == '11.0'">
      <PropertyGroup Condition="Exists('$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.0\Framework\v4.0\Microsoft.FSharp.Targets')">
        <FSharpTargetsPath>$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.0\Framework\v4.0\Microsoft.FSharp.Targets</FSharpTargetsPath>
      </PropertyGroup>
    </When>
    <Otherwise>
      <PropertyGroup Condition="Exists('$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\FSharp\Microsoft.FSharp.Targets')">
        <FSharpTargetsPath>$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\FSharp\Microsoft.FSharp.Targets</FSharpTargetsPath>
      </PropertyGroup>
    </Otherwise>
  </Choose>
  <Import Project="$(FSharpTargetsPath)" />
  1. run paket install

Expected behavior

Expect the Websharper targets to show up after the FSharp Targets import

Actual behavior

WebSharper Targets show up before the FSharp Targets import

@forki
Copy link
Member

forki commented Apr 8, 2016

which nuget package is that?

@ascjones
Copy link
Contributor Author

ascjones commented Apr 8, 2016

https://www.nuget.org/packages/WebSharper/3.6.11.234

I'm just guessing that it depends on FSharp targets, but anyway it works when the targets import it is below them.

@ascjones
Copy link
Contributor Author

ascjones commented Apr 8, 2016

Yep just confirmed, the WebSharper target import needs to appear after FSharp targets import in order to run, like so:

  <Import Project="$(FSharpTargetsPath)" />
  <Choose>
    <When Condition="$(TargetFrameworkIdentifier) == '.NETFramework' And $(TargetFrameworkVersion) == 'v4.5.1'">
      <PropertyGroup>
        <__paket__WebSharper_targets>WebSharper</__paket__WebSharper_targets>
      </PropertyGroup>
    </When>
  </Choose>

@forki forki added the bug label Apr 8, 2016
@forki
Copy link
Member

forki commented Apr 8, 2016

fix is under way

@forki forki closed this as completed in 776c1c7 Apr 8, 2016
@ascjones
Copy link
Contributor Author

ascjones commented Apr 8, 2016

Fantastic thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants