Add package deployment to local server to both projects

features/nuget_autobuild
Matija Koželj 2 years ago
parent dc49cac63a
commit 0f946cabe8

@ -20,6 +20,7 @@
<ItemGroup> <ItemGroup>
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly" Version="7.0.*-*" /> <PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly" Version="7.0.*-*" />
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.DevServer" Version="7.0.*-*" PrivateAssets="all" /> <PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.DevServer" Version="7.0.*-*" PrivateAssets="all" />
<PackageReference Include="Connected.Components" Version="1.0.*-*"/>
<PackageReference Include="Nerdbank.GitVersioning" <PackageReference Include="Nerdbank.GitVersioning"
Version="3.5.119" Version="3.5.119"
PrivateAssets="all" PrivateAssets="all"
@ -41,8 +42,8 @@
<Copy SourceFiles="$(OutputPath)..\$(PackageId).$(PackageVersion).snupkg" DestinationFolder="$([System.Environment]::GetEnvironmentVariable('LOCAL_NUGET'))" /> <Copy SourceFiles="$(OutputPath)..\$(PackageId).$(PackageVersion).snupkg" DestinationFolder="$([System.Environment]::GetEnvironmentVariable('LOCAL_NUGET'))" />
</Target> </Target>
<ItemGroup> <Target Name="UploadLocalPackages" AfterTargets="CopyPackages" >
<ProjectReference Include="..\connected.components\Connected.Components.csproj" /> <Exec Command="dotnet nuget push -s LocalNugetServer $(OutputPath)..\$(PackageId).$(PackageVersion).nupkg --api-key $([System.Environment]::GetEnvironmentVariable('LOCAL_NUGET_SERVER_TOKEN'))" IgnoreExitCode="true"></Exec>
</ItemGroup> <Exec Command="dotnet nuget push -s LocalNugetServer $(OutputPath)..\$(PackageId).$(PackageVersion).snupkg --api-key $([System.Environment]::GetEnvironmentVariable('LOCAL_NUGET_SERVER_TOKEN'))" IgnoreExitCode="true"></Exec>
</Target>
</Project> </Project>

@ -127,4 +127,9 @@
<ItemGroup> <ItemGroup>
<Content Include=".config\dotnet-tools.json" /> <Content Include=".config\dotnet-tools.json" />
</ItemGroup> </ItemGroup>
<Target Name="UploadLocalPackages" AfterTargets="CopyPackages" >
<Exec Command="dotnet nuget push -s LocalNugetServer $(OutputPath)..\$(PackageId).$(PackageVersion).nupkg --api-key $([System.Environment]::GetEnvironmentVariable('LOCAL_NUGET_SERVER_TOKEN'))" IgnoreExitCode="true"></Exec>
<Exec Command="dotnet nuget push -s LocalNugetServer $(OutputPath)..\$(PackageId).$(PackageVersion).snupkg --api-key $([System.Environment]::GetEnvironmentVariable('LOCAL_NUGET_SERVER_TOKEN'))" IgnoreExitCode="true"></Exec>
</Target>
</Project> </Project>

Loading…
Cancel
Save