[vcpkg] Error on '#' in version strings to avoid confusion#14927
Merged
ras0219-msft merged 6 commits intomicrosoft:masterfrom Dec 4, 2020
Merged
[vcpkg] Error on '#' in version strings to avoid confusion#14927ras0219-msft merged 6 commits intomicrosoft:masterfrom
ras0219-msft merged 6 commits intomicrosoft:masterfrom
Conversation
…roschuma/warn-port-version
5dc3778 to
9bb0ece
Compare
Contributor
|
That's awesome! |
strega-nil
approved these changes
Dec 4, 2020
strega-nil
pushed a commit
to strega-nil/vcpkg
that referenced
this pull request
May 5, 2021
…#14927) * [vcpkg] Refactor deserializers to reduce duplicate functionality * [vcpkg] Error on '#' in version strings to avoid confusion with port-version * [vcpkg] Improve error message * [vcpkg] Reorder field output * [vcpkg] Fix tests Co-authored-by: Robert Schumacher <roschuma@microsoft.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
With versioning, we will now be displaying versions to users either as
textortext#port-version. If a user sees this output and attempts to input it directly as a version constraint, it will not match and cause confusion.This PR makes
#s illegal in all version strings, reserving it for use for port-version suffixes. It then suggests how to fix the issue for users.As a drive by, this PR also refactors out the several copies of deserializing
version-xyz's.Example:
{ "$schema": "https://raw.githubusercontent.com/microsoft/vcpkg/master/scripts/vcpkg.schema.json", "name": "versiontest", "version-string": "2020-03-03", "description": [], "homepage": "", "dependencies": [ { "name": "fmt", "version>=": "1.0.0#2" } ] }+@strega-nil