Skip to content

Commit

Permalink
Second try on publishing github release notes to nuget (#922)
Browse files Browse the repository at this point in the history
  • Loading branch information
ivarne authored Nov 22, 2024
1 parent 2322191 commit 723992f
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
3 changes: 1 addition & 2 deletions .github/workflows/publish-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,7 @@ jobs:
- name: Pack
run: |
dotnet pack AppLibDotnet.sln --configuration Release --no-restore --no-build \
-p:Deterministic=true -p:BuildNumber=${{ github.run_number }} \
-p:PackageReleaseNotes="$(cat RELEASE_NOTES.md)"
-p:Deterministic=true -p:BuildNumber=${{ github.run_number }}
- name: Versions
run: |
dotnet --version
Expand Down
11 changes: 9 additions & 2 deletions src/Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,15 @@
<None Include="../../LICENSE" Pack="true" PackagePath="/" />
</ItemGroup>

<Target Name="PreparePackageReleaseNotesFromFile" BeforeTargets="GenerateNuspec">
<ReadLinesFromFile File="../../RELEASE_NOTES.md">
<Output TaskParameter="Lines" ItemName="ReleaseNoteLines" />
</ReadLinesFromFile>
<PropertyGroup>
<PackageReleaseNotes>@(ReleaseNoteLines, '%0a')</PackageReleaseNotes>
</PropertyGroup>
</Target>

<PropertyGroup>
<AnalysisMode>Recommended</AnalysisMode>
<ImplicitUsings>enable</ImplicitUsings>
Expand All @@ -23,13 +32,11 @@
<MinVerTagPrefix>v</MinVerTagPrefix>

<GenerateDocumentationFile>true</GenerateDocumentationFile>
<PackageReleaseNotes>https://github.com/Altinn/app-lib-dotnet/releases</PackageReleaseNotes>
<Authors>Altinn Platform Contributors</Authors>
<RepositoryType>git</RepositoryType>
<RepositoryUrl>https://github.com/Altinn/app-lib-dotnet</RepositoryUrl>
<PackageReadmeFile>README.md</PackageReadmeFile>
<PackageLicenseFile>LICENSE</PackageLicenseFile>

<PublishRepositoryUrl>true</PublishRepositoryUrl>
<EmbedUntrackedSources>true</EmbedUntrackedSources>
<IncludeSymbols>true</IncludeSymbols>
Expand Down

0 comments on commit 723992f

Please sign in to comment.