-
Notifications
You must be signed in to change notification settings - Fork 694
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
Expose original unmodified version string through read-only property #1325
Conversation
I'm fine with this change, but I am not sure this should ever be used over ToString(). If this is for the gallery we should normalize all SemVer 2.0.0 versions to avoid the confusion non-normalized versions cause. |
We already have this behavior in the V2 feed. The We improved this naming in V3. |
/// <summary> | ||
/// Returns the original, non-normalized version string. | ||
/// </summary> | ||
public string OriginalVersion |
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.
Nit: could be public string OriginalVersion => _originalString
right? I like that syntax 😄
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.
Done 4baa3cc
In that case, why allow a SemVer2 package to be uploaded where the normalized and non-normalized versions are different? I suppose the client should have thrown on these from the start and solving it here won't help. I just really want the normalized vs original issue to go away, it's painful. |
Fixes NuGet/Home#5068