Skip to content

Embed LICENSE.txt in NuGet package#14

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

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

Conversation

Copilot AI commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

The repository's LICENSE.txt was not being packed into the generated NuGet package(s), leaving consumers without license metadata in the published artifact.

Changes

  • Directory.Build.props: added PackageLicenseFile pointing to LICENSE.txt, and a Packed None item referencing the root LICENSE.txt, mirroring the existing pattern used for icon.png and readme.md.

This applies to all packable projects that import the shared Directory.Build.props, so no per-project changes are needed.

Verified locally that dotnet pack produces a .nuspec with:

<license type="file">LICENSE.txt</license>

and that LICENSE.txt is present at the root of the resulting .nupkg.

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 Embed LICENSE.txt in NuGet package Jul 9, 2026
Copilot AI requested a review from DecSmith42 July 9, 2026 11:58
@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 ensures the repository license is properly embedded in the produced NuGet packages by configuring a file-based license (PackageLicenseFile) and packing LICENSE.txt into the .nupkg, aligning with how the icon/readme are handled.

Changes:

  • Add PackageLicenseFile metadata so NuGet consumers see an explicit license file reference.
  • Pack the root LICENSE.txt into the NuGet package payload.

Comment thread Directory.Build.props Outdated
Comment thread Directory.Build.props Outdated
@DecSmith42
DecSmith42 disabled auto-merge July 9, 2026 12:14
- Renamed `readme.md` to `README.md` in `Directory.Build.props`.
- Adjusted file paths in `Directory.Build.props` to use `MSBuildThisFileDirectory` for accuracy.
- Removed redundant `<None Include>` entries from `_atom.csproj`.
- Added `.gitattributes` for consistent end-of-line handling of `*.verified.txt` and `*.received.txt`.
Copilot AI review requested due to automatic review settings July 9, 2026 12:43
@DecSmith42
DecSmith42 enabled auto-merge July 9, 2026 12:43

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.

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