Skip to content

Commit

Permalink
Merge pull request #151 from DuendeSoftware/dom/move-dependencies-to-…
Browse files Browse the repository at this point in the history
…target-file

Move all dependencies to .targets file
  • Loading branch information
brockallen authored Oct 19, 2022
2 parents 1ca3bff + 3905582 commit 62761f5
Show file tree
Hide file tree
Showing 8 changed files with 75 additions and 30 deletions.
1 change: 1 addition & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ jobs:
with:
dotnet-version: |
6.0.x
7.0.100-rc.2.22477.23
- run: dotnet --info

Expand Down
51 changes: 51 additions & 0 deletions Directory.Build.targets
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
<Project>

<PropertyGroup Condition=" '$(TargetFramework)' == 'net6.0'">
<FrameworkVersionRuntime>6.0.0</FrameworkVersionRuntime>
<FrameworkVersionTesting>6.0.0</FrameworkVersionTesting>
<YarpVersion>1.0.1</YarpVersion>
</PropertyGroup>

<PropertyGroup Condition=" '$(TargetFramework)' == 'net7.0'">
<FrameworkVersionRuntime>7.0.0-rc.2.*</FrameworkVersionRuntime>
<FrameworkVersionTesting>7.0.0-rc.2.*</FrameworkVersionTesting>
<YarpVersion>1.0.1</YarpVersion>
</PropertyGroup>

<ItemGroup>
<!-- build -->
<PackageReference Include="MinVer" Version="4.2.0" PrivateAssets="all" />
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="1.1.1" PrivateAssets="All" />

<!-- runtime -->
<PackageReference Update="Duende.AccessTokenManagement.OpenIdConnect" Version="1.0.0" />
<PackageReference Update="Microsoft.EntityFrameworkCore.Relational" Version="$(FrameworkVersionRuntime)" />
<PackageReference Update="Yarp.ReverseProxy" Version="$(YarpVersion)" />

<!-- testing -->
<PackageReference Update="Microsoft.EntityFrameworkCore.InMemory" Version="$(FrameworkVersionTesting)" />
<PackageReference Update="Microsoft.AspNetCore.Authentication.JwtBearer" Version="$(FrameworkVersionTesting)" />
<PackageReference Update="Microsoft.AspNetCore.TestHost" Version="$(FrameworkVersionTesting)" />

<PackageReference Update="Duende.IdentityServer" Version="6.1.5" />

<PackageReference Update="CsQuery.NETStandard" Version="1.3.6.1" />
<PackageReference Update="Microsoft.NET.Test.Sdk" Version="17.3.1" />
<PackageReference Update="xunit" Version="2.4.2" />
<PackageReference Update="xunit.runner.visualstudio" Version="2.4.5">
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
<PackageReference Update="FluentAssertions" Version="6.7.0" />
<PackageReference Update="coverlet.collector" Version="3.1.2">
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
</ItemGroup>

<Target Name="SetAssemblyVersion" AfterTargets="MinVer">
<PropertyGroup>
<AssemblyVersion>$(MinVerMajor).$(MinVerMinor).$(MinVerPatch).0</AssemblyVersion>
</PropertyGroup>
</Target>
</Project>
4 changes: 2 additions & 2 deletions global.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"sdk": {
"version": "6.0.100",
"version": "7.0.100-rc.2.22477.23",
"rollForward": "latestMajor",
"allowPrerelease": false
"allowPrerelease": true
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,8 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.EntityFrameworkCore.Relational" Version="6.0.0" />
<PackageReference Include="MinVer" Version="4.2.0" PrivateAssets="all" />
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="1.1.1" PrivateAssets="All" />

<PackageReference Include="Microsoft.EntityFrameworkCore.Relational" />

<ProjectReference Include="..\Duende.Bff\Duende.Bff.csproj" />
</ItemGroup>
</Project>
4 changes: 1 addition & 3 deletions src/Duende.Bff.Yarp/Duende.Bff.Yarp.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Yarp.ReverseProxy" Version="1.0.1" />
<PackageReference Include="MinVer" Version="4.2.0" PrivateAssets="all" />
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="1.1.1" PrivateAssets="All" />
<PackageReference Include="Yarp.ReverseProxy" />
</ItemGroup>

<ItemGroup>
Expand Down
5 changes: 1 addition & 4 deletions src/Duende.Bff/Duende.Bff.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,6 @@
<ItemGroup>
<FrameworkReference Include="Microsoft.AspNetCore.App" />

<PackageReference Include="MinVer" Version="4.2.0" PrivateAssets="all" />
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="1.1.1" PrivateAssets="All" />

<PackageReference Include="Duende.AccessTokenManagement.OpenIdConnect" Version="1.0.0" />
<PackageReference Include="Duende.AccessTokenManagement.OpenIdConnect" />
</ItemGroup>
</Project>
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net6.0</TargetFramework>
<TargetFrameworks>net6.0;net7.0</TargetFrameworks>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.3.1" />
<PackageReference Include="xunit" Version="2.4.2" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.5">
<PackageReference Include="Microsoft.NET.Test.Sdk" />
<PackageReference Include="xunit" />
<PackageReference Include="xunit.runner.visualstudio">
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
<PackageReference Include="FluentAssertions" Version="6.7.0" />
<PackageReference Include="coverlet.collector" Version="3.1.2">
<PackageReference Include="FluentAssertions" />
<PackageReference Include="coverlet.collector">
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>

<PackageReference Include="Microsoft.EntityFrameworkCore.InMemory" Version="6.0.9" />
<PackageReference Include="Microsoft.EntityFrameworkCore.InMemory" />
</ItemGroup>

<ItemGroup>
Expand Down
20 changes: 10 additions & 10 deletions test/Duende.Bff.Tests/Duende.Bff.Tests.csproj
Original file line number Diff line number Diff line change
@@ -1,27 +1,27 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net6.0</TargetFramework>
<TargetFrameworks>net6.0;net7.0</TargetFrameworks>
</PropertyGroup>


<ItemGroup>
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.3.1" />
<PackageReference Include="xunit" Version="2.4.2" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.5">
<PackageReference Include="Microsoft.NET.Test.Sdk" />
<PackageReference Include="xunit" />
<PackageReference Include="xunit.runner.visualstudio">
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
<PackageReference Include="FluentAssertions" Version="6.7.0" />
<PackageReference Include="coverlet.collector" Version="3.1.2">
<PackageReference Include="FluentAssertions" />
<PackageReference Include="coverlet.collector">
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
<PackageReference Include="CsQuery.NETStandard" Version="1.3.6.1" />
<PackageReference Include="CsQuery.NETStandard" />

<PackageReference Include="Duende.IdentityServer" Version="6.1.5" />
<PackageReference Include="Microsoft.AspNetCore.Authentication.JwtBearer" Version="6.0.9" />
<PackageReference Include="Microsoft.AspNetCore.TestHost" Version="6.0.9" />
<PackageReference Include="Duende.IdentityServer" />
<PackageReference Include="Microsoft.AspNetCore.Authentication.JwtBearer" />
<PackageReference Include="Microsoft.AspNetCore.TestHost" />
</ItemGroup>

<ItemGroup>
Expand Down

0 comments on commit 62761f5

Please sign in to comment.