Skip to content

Embed LICENSE.txt in NuGet package#12

Merged
DecSmith42 merged 5 commits into
mainfrom
copilot/embed-license-in-nuget
Jul 9, 2026
Merged

Embed LICENSE.txt in NuGet package#12
DecSmith42 merged 5 commits into
mainfrom
copilot/embed-license-in-nuget

Conversation

Copilot AI commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

The repo's LICENSE.txt was not being packed into the NuGet output, so consumers had no license metadata bundled with the package.

Changes

  • Added PackageLicenseFile property in Directory.Build.props, pointing to LICENSE.txt
  • Added a Pack="true" item to include LICENSE.txt at the package root, alongside the existing icon and readme entries

Since this lives in the shared Directory.Build.props, it applies to any current or future packable project in the solution without per-project changes.

Confirmed via dotnet pack that the resulting .nupkg now contains LICENSE.txt and the .nuspec declares <license type="file">LICENSE.txt</license>.

Copilot AI requested review from Copilot and removed request for Copilot July 9, 2026 11:56
Copilot AI linked an issue Jul 9, 2026 that may be closed by this pull request
Copilot AI requested review from Copilot and removed request for Copilot July 9, 2026 11:58
Copilot AI changed the title [WIP] Embed license in NuGet package output Embed LICENSE.txt in NuGet package Jul 9, 2026
Copilot AI requested a review from DecSmith42 July 9, 2026 11:59
@DecSmith42
DecSmith42 marked this pull request as ready for review July 9, 2026 12:00
Copilot AI review requested due to automatic review settings July 9, 2026 12:00
@DecSmith42
DecSmith42 enabled auto-merge July 9, 2026 12:02

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the repo-wide NuGet packing settings so that LICENSE.txt is included in the produced .nupkg and referenced via PackageLicenseFile, ensuring consumers receive license metadata with the package.

Changes:

  • Adds PackageLicenseFile to NuGet package metadata.
  • Packs LICENSE.txt into the package root via a None item with Pack="true".

Comment thread Directory.Build.props
Comment thread Directory.Build.props Outdated
@DecSmith42
DecSmith42 disabled auto-merge July 9, 2026 12:14
Copilot AI review requested due to automatic review settings July 9, 2026 12:24
@DecSmith42
DecSmith42 enabled auto-merge July 9, 2026 12:24

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated no new comments.

Copilot AI review requested due to automatic review settings July 9, 2026 12:41

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated no new comments.

@DecSmith42
DecSmith42 merged commit 6bc9208 into main Jul 9, 2026
14 checks passed
@DecSmith42
DecSmith42 deleted the copilot/embed-license-in-nuget branch July 9, 2026 13:17
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.

Embed license in nuget

3 participants