-
-
Notifications
You must be signed in to change notification settings - Fork 14.7k
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
buildDotnetModule
: add support for installing pre-release tools
#374663
base: master
Are you sure you want to change the base?
Conversation
I can't think of a good reason not to do this in the install. The version is pinned in the derivation. Would specifying the version ( Explicitly allowing prerelease versions could still be relevant for the update script:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The fixup commit should be squashed.
I'll do some more checks. Just noticed the command errors out if we pass both version and pre release flags... But I agree we should pass the pinned version to the DotNet tool installation command. I'll also update the regex in the install script. |
buildDotnetModule
: add support for installing pre-release toolsbuildDotnetModule
: add support for installing pre-release tools
f4a0a1e
to
5edf781
Compare
buildDotnetModule
: add support for installing pre-release toolsbuildDotnetModule
: add support for installing pre-release tools
5edf781
to
4568254
Compare
You are absolutely correct, @corngood : replacing I modified the regex in All commits are now squashed. |
|
version=$(curl -fsSL "https://api.nuget.org/v3-flatcontainer/$nugetName/index.json" | | ||
jq -er '.versions | last(.[] | select(match("^[0-9]+\\.[0-9]+\\.[0-9]+$")))') | ||
jq -er '.versions | last(.[] | select(match("^[0-9]+\\.[0-9]+\\.[0-9]+(-[0-9A-Za-z.-]+)?(\\+[0-9A-Za-z.-]+)?$")))') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think we want to do this by default. This will cause all the existing packages to update to pre-release automatically.
If we're going to do this it should be gated by something like allowPrerelease
, but it may not be worth the trouble. We may not want things doing automatic updates to prerelease versions at all.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think my suggestion would be to just leave this out for now.
4568254
to
149eb99
Compare
Things done
Added an optional
allowPreRelease
argument tobuildDotnetModule
that will set the--prerelease
flag to thedotnet tool install
command.This is because some useful Nuget packages have a tendency to stay in alpha release, so it's nice to be able to package them regardless.
We could also add the
--prerelease
tag unconditionally if that would be acceptable.nix.conf
? (See Nix manual)sandbox = relaxed
sandbox = true
nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"
. Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/
)Add a 👍 reaction to pull requests you find important.