Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NuGetPushSettings.Source: incorrect documentation #1213

Closed
Jericho opened this issue Sep 6, 2016 · 7 comments
Closed

NuGetPushSettings.Source: incorrect documentation #1213

Jericho opened this issue Sep 6, 2016 · 7 comments
Milestone

Comments

@Jericho
Copy link
Contributor

Jericho commented Sep 6, 2016

Regarding NuGetPushSettings.Source: documentation says If not specified, nuget.org is used. However, when this value is null I am getting the following error: Source parameter was not specified.

The documentation in question is here: http://cakebuild.net/api/cake.common.tools.nuget.push/bcd6313b
and also here: http://cakebuild.net/api/cake.common.tools.nuget.push/bcd6313b/83747a07

By the way, since there is no 'default' value, we should document the most common values (e.g.: nuget.org, myget, etc.).

@devlead
Copy link
Member

devlead commented Sep 6, 2016

This is a change on the NuGet.exe, we've added a note on the aliases
https://github.com/cake-build/cake/blob/develop/src/Cake.Common/Tools/NuGet/NuGetAliases.cs#L295-L296

So it's mandatory depending which version of the tool you're using, could likely make even more clear if we added it here too
https://github.com/cake-build/cake/blob/develop/src/Cake.Common/Tools/NuGet/Push/NuGetPushSettings.cs#L23

@Jericho
Copy link
Contributor Author

Jericho commented Sep 6, 2016

I understand that it's mandatory, but the documentation says otherwise.

@Jericho
Copy link
Contributor Author

Jericho commented Sep 6, 2016

Also, despite my best efforts I could not find the appropriate value for nuget. I asked about it on gitter and @gep13 told me it was https://nuget.org/api/v2/package.

I'm sure I'm not the only one who struggled to figue this out so that's why I suggested documenting the URL for nuget, myget, etc.

@devlead
Copy link
Member

devlead commented Sep 6, 2016

Yes, agree, great feedback.

We've documented this change of behavior on the aliases i.e.
http://cakebuild.net/api/cake.common.tools.nuget/bdfa6572/41c53943

But not updated docs on settings source property, which would be a great addition to clarify too.
Adding the nuget.org push url as an example also sounds like an good addition to here

Our docs are auto generated from source code, there's one source of truth. Gladly accept good docs PRs, once merged, they'll show up on our web post next release.

You can read more about the NuGet authoring in general here

The docs were correct when written, we just have to get with the times ;) Parameter it's still optional with any nuget.exe version pre 3.4.2 or if you have a default push source specified in your nuget.config.

<add key="DefaultPushSource" value="http://MyRepo/ES/api/v2/package" />

You can read more about nuget.config here

@gep13
Copy link
Member

gep13 commented Feb 14, 2018

@Jericho i don't think this work has been completed yet. Why close the issue?

@Jericho
Copy link
Contributor Author

Jericho commented Feb 14, 2018

@gep13 a year and a half later, I didn't think anybody was paying attention anymore.

@gep13
Copy link
Member

gep13 commented Feb 14, 2018

In Open Source terms, that really isn't long. I think the first PR I created took 2 years to be pulled in. If the issue is still present, I would prefer that it stay open.

@Jericho Jericho reopened this Feb 14, 2018
Jericho added a commit to Jericho/cake that referenced this issue Feb 18, 2018
Document the fact that NuGetPushSettings.Source is mandatory since nuget 3.4.2 and also document the url for two of the most popular public nuget servers (nuget.org and myget).

Resolves cake-build#1213
@gep13 gep13 added this to the v0.27.0 milestone Feb 22, 2018
devlead pushed a commit to Jericho/cake that referenced this issue Mar 13, 2018
* Document the fact that NuGetPushSettings.Source is mandatory since nuget 3.4.2 and also document the url for two of the most popular public nuget servers (nuget.org and myget).
* Resolves cake-build#1213
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants