You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Support for a repository property in NuGet .nuspec files was added a while back, with the idea being that this would make tracking both the project's website (using the existing projectUrl property) and the package's source code (using the new repository property) clearer.
Chocolatey already had the packageSourceUrl property to achieve this.
However, some package repositories, such as GitHub Packages, will now not allow packages to be uploaded without the repository property being set in the .nuspec file:
WARNING: No destination repository detected. Ensure the source project has a 'RepositoryUrl' property defined. If you're using a nuspec file, ensure that it has a repository element with the required 'type' and 'url' attributes.
I believe this leaves 4 options:
Add support in choco pack for the repository property alongside the existing packageSourceUrl property.
Backwards-compatible, and allows GitHub Packages to be used as an package repository.
Will lead to duplicated properties if used (i.e. the repository property and the packageSourceUrl property would be set to the same value).
Automatically transform the existing packageSourceUrl property into the repository property in choco pack's generated .nuspec.
Not backwards-compatible, will cause existing tools that depend on packageSourceUrl to break.
Cleaner than option 1 - no duplicate properties.
Require the repository property to be used in .nuspec files rather than the packageSourceUrl property.
Not backwards-compatible, publishers will have to update their .nuspec files.
Existing tools that depend on packageSourceUrl will have to check for the repository property first, then fallback to using the packageSourceUrl.
Do nothing
Prevents GitHub Packages and possibly other package repositories that use the current .nuspec specification from being used.
Divergence between NuGet .nuspec files and Chocolatey .nuspec files. Whilst they are different tools, given that Chocolatey leverages NuGet package repositories, I think as much compatibility as possible should be the goal?
Happy to contribute, but I think this requires input from others before making PRs and changes.
The text was updated successfully, but these errors were encountered:
This feels like it has overlap in #508, maybe even depends on that aspect. Like GitHub repositories only support NuGet v3, not NuGet v2, which Chocolatey would need at this time.
Support for a
repository
property in NuGet.nuspec
files was added a while back, with the idea being that this would make tracking both the project's website (using the existingprojectUrl
property) and the package's source code (using the newrepository
property) clearer.Chocolatey already had the
packageSourceUrl
property to achieve this.However, some package repositories, such as GitHub Packages, will now not allow packages to be uploaded without the
repository
property being set in the.nuspec
file:I believe this leaves 4 options:
choco pack
for therepository
property alongside the existingpackageSourceUrl
property.repository
property and thepackageSourceUrl
property would be set to the same value).packageSourceUrl
property into therepository
property inchoco pack
's generated.nuspec
.packageSourceUrl
to break.repository
property to be used in.nuspec
files rather than thepackageSourceUrl
property..nuspec
files.packageSourceUrl
will have to check for therepository
property first, then fallback to using thepackageSourceUrl
..nuspec
specification from being used..nuspec
files and Chocolatey.nuspec
files. Whilst they are different tools, given that Chocolatey leverages NuGet package repositories, I think as much compatibility as possible should be the goal?Happy to contribute, but I think this requires input from others before making PRs and changes.
The text was updated successfully, but these errors were encountered: