-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Description
I'm having a problem and would like to a feature.
My current problem is:
I would like to publish prerelease versions with dashes, eg something like 1.2.0.pre-update-logo. This appears to not be possible as of rubygems version 3.0.4:
irb(main):001:0> Gem::Version.new('1.2.0.pre-update-logo')
=> #<Gem::Version "1.2.0.pre.pre.update.pre.logo">
The -'s are all replaced by .pre. which is fairly unhelpful (except possibly the first replacement). That happens here: https://github.com/rubygems/rubygems/blob/d8fa21e82b5669880331e2fe236b2cede1d6c4fb/lib/rubygems/version.rb#L221
Dashes in prerelease versions are allowed by the SemVer spec:
A pre-release version MAY be denoted by appending a hyphen and a series of dot separated identifiers immediately following the patch version. Identifiers MUST comprise only ASCII alphanumerics and hyphen [0-9A-Za-z-]
Note that I'm not asking about "FULL SEMVER", but only about dashes in prerelease labels
This issue is related to:
- Network problems
- Installing a library
- Publishing a library
- The command line
gem - Other
Other issues:
- Support for full Semantic versioning Support for full Semantic versioning #592
- Match rubygems not-quite-Semver versioning for pre-release versioning Please backport r31914 and r31915 from Ruby trunk #86
Here are my current environment details:
$ gem env version
RubyGems Environment:
- RUBYGEMS VERSION: 3.0.4
- RUBY VERSION: 2.5.3 (2018-10-18 patchlevel 105) [x86_64-linux]
(etc, n/a)
I will abide by the code of conduct.