Skip to content

Bugfix/no support of wildcard directly #12

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

Merged
merged 4 commits into from
Jan 26, 2022

Conversation

MartinCarpentier
Copy link
Contributor

@MartinCarpentier MartinCarpentier commented Jan 11, 2022

The dotnet nuget push command does not allow wildcards.

I updated the release action with some powershell code, that will function the same way as I expect the wildcard was meant to function.
It uses Get-ChildItem to find the nuget package, and pushes the top 1 result.

Tested on my own fork, and it seems like it finds the correct package, but have not tested the nuget push itself.

Martin Boje Carpentier added 3 commits January 2, 2022 09:59
… i edited the command, to first retrieve the most recent nupkg package using Get-ChildItem which supports wildcards, and then push the result
@MartinCarpentier
Copy link
Contributor Author

@matt-lethargic This merge request should fix the release part. (hopefully)

run: |
Copy link
Member

Choose a reason for hiding this comment

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

Do we not already have the version number to enable us to build the correct file name to use with nuget push?

Copy link
Member

Choose a reason for hiding this comment

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

And nuget push should work with wildcards as I do it for my day job: https://github.com/Nexmo/github-actions/blob/main/nuget-release/index.js

Copy link
Contributor Author

Choose a reason for hiding this comment

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

You are completely right. We do have the version number, and in theory the wildcard should not be needed.

Arh and i see, i just read around and it seemed like PowerShell didn't have as good wildcard support as bash, and the error was this.

image

So it seemed like the wildcard was taken as the path itself.

Should i fix the wildcard, or should i just bind to the actual nuget package directly.
What's your thought?

Copy link
Member

Choose a reason for hiding this comment

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

Personally I'd use the exact path using the version number if possible. But it's entirely up to you. If it works, it works.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes, that seems like the best solution.
I will fix it.

@MartinCarpentier MartinCarpentier merged commit 2ba06a1 into main Jan 26, 2022
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.

2 participants