Skip to content

Commit

Permalink
Pubhlish to nuget (#484)
Browse files Browse the repository at this point in the history
* Pubhlish to nuget

* Fixed lines

* Packing again
  • Loading branch information
abergs authored Jan 3, 2024
1 parent f098827 commit d847702
Show file tree
Hide file tree
Showing 8 changed files with 10 additions and 15 deletions.
11 changes: 5 additions & 6 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -200,10 +200,9 @@ jobs:
--api-key ${{ secrets.GITHUB_TOKEN }}
# Only publish to NuGet on stable releases
# Repeat the run for these inputs: Fido2, Fido2.Models, Fido2.Aspnet
- name: Publish package to NuGet Registry
- name: Publish packages (NuGet Registry)
if: ${{ github.event_name == 'release' }}
run: |
dotnet nuget push **/Fido2.nupkg --source "https://api.nuget.org/v3/index.json" --api-key "${{ secrets.nuget_api_key }}"
dotnet nuget push **/Fido2.Models.nupkg --source "https://api.nuget.org/v3/index.json" --api-key "${{ secrets.nuget_api_key }}"
dotnet nuget push **/Fido2.AspNet.nupkg --source "https://api.nuget.org/v3/index.json" --api-key "${{ secrets.nuget_api_key }}"
run: >
dotnet nuget push **/*.nupkg
--source https://api.nuget.org/v3/index.json
--api-key ${{ secrets.nuget_api_key }}
1 change: 1 addition & 0 deletions Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
<PropertyGroup>
<!-- Avoid annoying build warnings when packing using the solution file -->
<IsPackable>false</IsPackable>
<GeneratePackageOnBuild>false</GeneratePackageOnBuild>
<!-- Avoid annoying build warnings when packing using the solution file -->
<IsTestProject>false</IsTestProject>
</PropertyGroup>
Expand Down
8 changes: 1 addition & 7 deletions Src/Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,5 @@
</PropertyGroup>
<ItemGroup Condition="$(IS_DOCKER) == ''">
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="1.1.1" PrivateAssets="All" />
</ItemGroup>

<!-- Projects inside "./src" should generate packages -->
<PropertyGroup>
<IsPackable>true</IsPackable>
<GeneratePackageOnBuild>false</GeneratePackageOnBuild>
</PropertyGroup>
</ItemGroup>
</Project>
1 change: 1 addition & 0 deletions Src/Fido2.AspNet/Fido2.AspNet.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
<PropertyGroup>
<TargetFrameworks>$(SupportedTargetFrameworks)</TargetFrameworks>
<RootNamespace>Fido2NetLib</RootNamespace>
<IsPackable>true</IsPackable>
</PropertyGroup>

<ItemGroup>
Expand Down
1 change: 1 addition & 0 deletions Src/Fido2.Models/Fido2.Models.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
<GenerateDocumentationFile>true</GenerateDocumentationFile>
<IsTrimmable>true</IsTrimmable>
<NoWarn>$(NoWarn);CS1591</NoWarn>
<IsPackable>true</IsPackable>
</PropertyGroup>

</Project>
1 change: 1 addition & 0 deletions Src/Fido2/Fido2.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
<ImplicitUsings>disable</ImplicitUsings>
<IsTrimmable>true</IsTrimmable>
<NoWarn>$(NoWarn);IDE0057</NoWarn>
<IsPackable>true</IsPackable>
</PropertyGroup>

<ItemGroup>
Expand Down
1 change: 0 additions & 1 deletion Test/Test.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

<PropertyGroup>
<TargetFrameworks>$(SupportedTargetFrameworks)</TargetFrameworks>
<IsPackable>false</IsPackable>
<NoWarn>$(NoWarm);CA1822;IDE0007;IDE0037;IDE0039;IDE0057;CA1825</NoWarn>
</PropertyGroup>

Expand Down
1 change: 0 additions & 1 deletion Tests/Fido2.Ctap2.Tests/Fido2.Ctap2.Tests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
<PropertyGroup>
<TargetFrameworks>$(SupportedTargetFrameworks)</TargetFrameworks>
<Nullable>enable</Nullable>
<IsPackable>false</IsPackable>
</PropertyGroup>

<ItemGroup>
Expand Down

0 comments on commit d847702

Please sign in to comment.