Skip to content

Conversation

@KevinRansom
Copy link
Contributor

@KevinRansom KevinRansom commented Jan 23, 2018

Type providers may be split into two portions a runtime helpers library and a design time library to run in the compiler/fcs/fsi etc ...

This PR makes dotnet pack easier.

Example projects:

This Example consists of a runtime project a design time project
The design time project is a project reference it is tagged with:

      <IsFSharpDesignTimeProvider>true</IsFSharpDesignTimeProvider>
      <PrivateAssets>all</PrivateAssets>

Private Assets, stops the build and nuget from making the DesignTime assembly a dependency of the package.

The package layout conforms to : #3864

However, nuget doesn't make make specific target runtimes subdirectories of the TargetFramework, so neither does this. nugget uses the runtime branch for runtime specific probing.

I propose revising the current probing logic to stop probing for x86 and x64.

Additionally:

  • DesignTime Assemblies will cover extensions other than TypeProviders moving forward.
  • 'typeproviders' causes nuget packaging warnings

The default here is to place designtime assemblies below tool. To place them below typeproviders
use:

<FSharpToolsDirectory>typeproviders</<FSharpToolsDirectory>
<Project Sdk="Microsoft.NET.Sdk">

  <PropertyGroup>
    <TargetFrameworks>net461;netstandard2.0</TargetFrameworks>
  </PropertyGroup>

  <ItemGroup>
    <Compile Include="BasicProvider.Runtime.fs" />
  </ItemGroup>

  <ItemGroup>
    <ProjectReference Include="..\BasicProvider.DesignTime\BasicProvider.DesignTime.fsproj">
      <IsFSharpDesignTimeProvider>true</IsFSharpDesignTimeProvider>
      <PrivateAssets>all</PrivateAssets>
    </ProjectReference>
  </ItemGroup>

</Project>


@KevinRansom KevinRansom merged commit 6cb64f2 into dotnet:master Jan 23, 2018
@KevinRansom KevinRansom deleted the typeproviderpack branch August 2, 2018 18:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant