version_gem 1.1.0 → 1.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data/CHANGELOG.md +36 -22
- data/README.md +17 -6
- data/SECURITY.md +3 -3
- data/lib/version_gem/api.rb +7 -7
- data/lib/version_gem/version.rb +1 -1
- data.tar.gz.sig +0 -0
- metadata +46 -16
- metadata.gz.sig +1 -0
- data/sig/version_gem.rbs +0 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 617f64c21f615e873f17b3774d4cc1e156d10f276c670f7f84308b2fd0853d75
|
4
|
+
data.tar.gz: '082c40a241be990945f0f4c9939419b5aa49c632bc1ff77e2ab9459736855519'
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 396d61f301aac49502dcef070dcbca71343b9e1532062e8b5c90b2dfbb1d2bd63d714ea8261c76bcbb2048c49de2810742cfba8235b048b7c958dc567f57da66
|
7
|
+
data.tar.gz: 2f8a9fabf0e1388528fc25ee8e6372c9347413acb3ad31726a831b768c49df2da5f493de4f290039d4afb4248855e1a963967abd835151271db11f3193124df0
|
checksums.yaml.gz.sig
ADDED
Binary file
|
data/CHANGELOG.md
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
|
1
|
+
# Changelog
|
2
2
|
All notable changes to this project will be documented in this file.
|
3
3
|
|
4
4
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
@@ -6,36 +6,50 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
6
6
|
|
7
7
|
## [Unreleased]
|
8
8
|
### Added
|
9
|
-
|
10
9
|
### Changed
|
11
|
-
|
12
10
|
### Fixed
|
13
|
-
|
14
11
|
### Removed
|
15
12
|
|
16
|
-
## [1.1.
|
17
|
-
### Fixed
|
18
|
-
- to_a uses same type casting as major, minor, patch, and pre
|
13
|
+
## [1.1.1] - 2022-09-19 ([tag][1.1.1t])
|
19
14
|
### Added
|
20
|
-
-
|
15
|
+
- Alternatives section to README.md (@pboling)
|
16
|
+
- Signing cert for gem releases (@pboling)
|
17
|
+
- Mailing List and other metadata URIs (@pboling)
|
18
|
+
- Checksums for released gems (@pboling)
|
19
|
+
### Changed
|
20
|
+
- SECURITY.md policy (@pboling)
|
21
|
+
- Version methods are now memoized (||=) on initial call for performance (@pboling)
|
22
|
+
- Gem releases are now cryptographically signed (@pboling)
|
21
23
|
|
22
|
-
## [1.0
|
24
|
+
## [1.1.0] - 2022-06-24 ([tag][1.1.0t])
|
25
|
+
### Fixed
|
26
|
+
- to_a uses same type casting as major, minor, patch, and pre (@pboling)
|
23
27
|
### Added
|
24
|
-
-
|
28
|
+
- RSpec Matchers and Shared Example (@pboling)
|
25
29
|
|
26
|
-
## [1.0.
|
30
|
+
## [1.0.2] - 2022-06-23 ([tag][1.0.2t])
|
27
31
|
### Added
|
28
|
-
-
|
29
|
-
- Code coverage reporting
|
30
|
-
- Documentation improvements
|
31
|
-
- Badges!
|
32
|
+
- Delay loading of library code until after code coverage tool is loaded (@pboling)
|
32
33
|
|
33
|
-
## [1.0.
|
34
|
+
## [1.0.1] - 2022-06-23 ([tag][1.0.1t])
|
34
35
|
### Added
|
35
|
-
-
|
36
|
+
- CI Build improvements (@pboling)
|
37
|
+
- Code coverage reporting (@pboling)
|
38
|
+
- Documentation improvements (@pboling)
|
39
|
+
- Badges! (@pboling)
|
36
40
|
|
37
|
-
[
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
[
|
41
|
+
## [1.0.0] - 2022-06-21 ([tag][1.0.0t])
|
42
|
+
### Added
|
43
|
+
- Initial release, with basic version parsing API (@pboling)
|
44
|
+
|
45
|
+
[Unreleased]: https://gitlab.com/oauth-xx/version_gem/-/compare/v1.1.1...HEAD
|
46
|
+
[1.1.1]: https://gitlab.com/oauth-xx/version_gem/-/compare/v1.1.0...v1.1.1
|
47
|
+
[1.1.1t]: https://gitlab.com/oauth-xx/oauth2/-/tags/v1.1.1
|
48
|
+
[1.1.0]: https://gitlab.com/oauth-xx/version_gem/-/compare/v1.0.2...v1.1.0
|
49
|
+
[1.1.0t]: https://gitlab.com/oauth-xx/oauth2/-/tags/v1.1.0
|
50
|
+
[1.0.2]: https://gitlab.com/oauth-xx/version_gem/-/compare/v1.0.1...v1.0.2
|
51
|
+
[1.0.2t]: https://gitlab.com/oauth-xx/oauth2/-/tags/v1.0.2
|
52
|
+
[1.0.1]: https://gitlab.com/oauth-xx/version_gem/-/compare/v1.0.0...v1.0.1
|
53
|
+
[1.0.1t]: https://gitlab.com/oauth-xx/oauth2/-/tags/v1.0.1
|
54
|
+
[1.0.0]: https://gitlab.com/oauth-xx/version_gem/-/compare/a3055964517c159bf214712940982034b75264be...v1.0.0
|
55
|
+
[1.0.0t]: https://gitlab.com/oauth-xx/oauth2/-/tags/v1.0.0
|
data/README.md
CHANGED
@@ -1,6 +1,21 @@
|
|
1
1
|
# VersionGem
|
2
2
|
|
3
|
-
|
3
|
+
## Alternatives
|
4
|
+
|
5
|
+
This gem has a very niche purpose, which is:
|
6
|
+
|
7
|
+
1. providing introspection of a `Version` module based on a `Version::VERSION` constant string,
|
8
|
+
2. while not interfering with `gemspec` parsing where the `VERSION` string is traditionally used.
|
9
|
+
|
10
|
+
If this isn't **precisely** your use case you may be better off looking at
|
11
|
+
[`Versionaire`](https://www.alchemists.io/projects/versionaire), a wonderful, performant, well-maintained,
|
12
|
+
gem from the Alchemists.
|
13
|
+
|
14
|
+
For more discussion about this [see issue #2](https://github.com/pboling/version_gem/issues/2)
|
15
|
+
|
16
|
+
## Still here?
|
17
|
+
|
18
|
+
Give your next library an introspectable `Version` module without breaking your Gemspec.
|
4
19
|
|
5
20
|
```ruby
|
6
21
|
MyLib::Version.to_s # => "1.2.3.rc3"
|
@@ -40,7 +55,7 @@ badge #s:
|
|
40
55
|
📗
|
41
56
|
|
42
57
|
appended indicators:
|
43
|
-
♻️ - URL needs to be updated from
|
58
|
+
♻️ - URL needs to be updated from SAAS integration. Find / Replace is insufficient.
|
44
59
|
-->
|
45
60
|
|
46
61
|
| | Project | bundle add version_gem |
|
@@ -316,10 +331,6 @@ See [SECURITY.md](https://github.com/pboling/version_gem/blob/main/SECURITY.md).
|
|
316
331
|
|
317
332
|
[pvc]: http://guides.rubygems.org/patterns/#pessimistic-version-constraint
|
318
333
|
|
319
|
-
[railsbling]: http://www.railsbling.com
|
320
|
-
|
321
|
-
[peterboling]: http://www.peterboling.com
|
322
|
-
|
323
334
|
[aboutme]: https://about.me/peter.boling
|
324
335
|
|
325
336
|
[angelme]: https://angel.co/peter-boling
|
data/SECURITY.md
CHANGED
data/lib/version_gem/api.rb
CHANGED
@@ -11,35 +11,35 @@ module VersionGem
|
|
11
11
|
#
|
12
12
|
# @return [Integer]
|
13
13
|
def major
|
14
|
-
_to_a[0].to_i
|
14
|
+
@major ||= _to_a[0].to_i
|
15
15
|
end
|
16
16
|
|
17
17
|
# The minor version
|
18
18
|
#
|
19
19
|
# @return [Integer]
|
20
20
|
def minor
|
21
|
-
_to_a[1].to_i
|
21
|
+
@minor ||= _to_a[1].to_i
|
22
22
|
end
|
23
23
|
|
24
24
|
# The patch version
|
25
25
|
#
|
26
26
|
# @return [Integer]
|
27
27
|
def patch
|
28
|
-
_to_a[2].to_i
|
28
|
+
@patch ||= _to_a[2].to_i
|
29
29
|
end
|
30
30
|
|
31
31
|
# The pre-release version, if any
|
32
32
|
#
|
33
33
|
# @return [String, NilClass]
|
34
34
|
def pre
|
35
|
-
_to_a[3]
|
35
|
+
@pre ||= _to_a[3]
|
36
36
|
end
|
37
37
|
|
38
38
|
# The version number as a hash
|
39
39
|
#
|
40
40
|
# @return [Hash]
|
41
41
|
def to_h
|
42
|
-
{
|
42
|
+
@to_h ||= {
|
43
43
|
major: major,
|
44
44
|
minor: minor,
|
45
45
|
patch: patch,
|
@@ -51,7 +51,7 @@ module VersionGem
|
|
51
51
|
#
|
52
52
|
# @return [Array<[Integer, String, NilClass]>]
|
53
53
|
def to_a
|
54
|
-
[major, minor, patch, pre]
|
54
|
+
@to_a ||= [major, minor, patch, pre]
|
55
55
|
end
|
56
56
|
|
57
57
|
private
|
@@ -60,7 +60,7 @@ module VersionGem
|
|
60
60
|
#
|
61
61
|
# @return [Array<String>]
|
62
62
|
def _to_a
|
63
|
-
self::VERSION.split('.')
|
63
|
+
@_to_a = self::VERSION.split('.')
|
64
64
|
end
|
65
65
|
end
|
66
66
|
end
|
data/lib/version_gem/version.rb
CHANGED
data.tar.gz.sig
ADDED
Binary file
|
metadata
CHANGED
@@ -1,14 +1,42 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: version_gem
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Peter Boling
|
8
|
-
autorequire:
|
9
|
-
bindir:
|
10
|
-
cert_chain:
|
11
|
-
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain:
|
11
|
+
- |
|
12
|
+
-----BEGIN CERTIFICATE-----
|
13
|
+
MIIEgDCCAuigAwIBAgIBATANBgkqhkiG9w0BAQsFADBDMRUwEwYDVQQDDAxwZXRl
|
14
|
+
ci5ib2xpbmcxFTATBgoJkiaJk/IsZAEZFgVnbWFpbDETMBEGCgmSJomT8ixkARkW
|
15
|
+
A2NvbTAeFw0yMjA5MTgyMzEyMzBaFw0yMzA5MTgyMzEyMzBaMEMxFTATBgNVBAMM
|
16
|
+
DHBldGVyLmJvbGluZzEVMBMGCgmSJomT8ixkARkWBWdtYWlsMRMwEQYKCZImiZPy
|
17
|
+
LGQBGRYDY29tMIIBojANBgkqhkiG9w0BAQEFAAOCAY8AMIIBigKC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ZyYniWK05zdhIi956ynhfGaFO988FFdVw5Jq
|
33
|
+
LHtXfIpAU8F7ES04syZSslxOluw7VlcSKyRdVIr737J92ZTduppB4PRGSKRgBsWV
|
34
|
+
hXTahRE72Kyw53Q7FAuzF3v102WxAAQ7BuMjW+MyCUT75fwPm3W4ELPL8HYkNGE7
|
35
|
+
2oA5CPghFitRnvYS3GNrDG+9bNiRMEskeaBYwZ9UgReBQIwGYVj7LZk3UhiAsn44
|
36
|
+
gwGrEXGQGDZ0NIgBcmvMOqlXjkGQwQvugKycJ024z89+fz2332vdZIKTrSxJrXGk
|
37
|
+
4/bR9A==
|
38
|
+
-----END CERTIFICATE-----
|
39
|
+
date: 2022-09-19 00:00:00.000000000 Z
|
12
40
|
dependencies:
|
13
41
|
- !ruby/object:Gem::Dependency
|
14
42
|
name: rspec
|
@@ -103,6 +131,7 @@ dependencies:
|
|
103
131
|
description: Versions are good. Versions are cool. Versions will win.
|
104
132
|
email:
|
105
133
|
- peter.boling@gmail.com
|
134
|
+
- oauth-ruby@googlegroups.com
|
106
135
|
executables: []
|
107
136
|
extensions: []
|
108
137
|
extra_rdoc_files: []
|
@@ -119,19 +148,20 @@ files:
|
|
119
148
|
- lib/version_gem/error.rb
|
120
149
|
- lib/version_gem/rspec.rb
|
121
150
|
- lib/version_gem/version.rb
|
122
|
-
|
123
|
-
homepage: https://github.com/pboling/version_gem
|
151
|
+
homepage: https://gitlab.com/oauth-xx/version_gem
|
124
152
|
licenses:
|
125
153
|
- MIT
|
126
154
|
metadata:
|
127
|
-
homepage_uri: https://
|
128
|
-
source_code_uri: https://
|
129
|
-
changelog_uri: https://
|
130
|
-
bug_tracker_uri: https://
|
131
|
-
documentation_uri: https://www.rubydoc.info/gems/version_gem/1.1.
|
132
|
-
wiki_uri: https://
|
155
|
+
homepage_uri: https://gitlab.com/oauth-xx/version_gem
|
156
|
+
source_code_uri: https://gitlab.com/oauth-xx/version_gem/-/tree/v1.1.1
|
157
|
+
changelog_uri: https://gitlab.com/oauth-xx/version_gem/-/blob/v1.1.1/CHANGELOG.md
|
158
|
+
bug_tracker_uri: https://gitlab.com/oauth-xx/version_gem/-/issues
|
159
|
+
documentation_uri: https://www.rubydoc.info/gems/version_gem/1.1.1
|
160
|
+
wiki_uri: https://gitlab.com/oauth-xx/version_gem/-/wiki
|
161
|
+
mailing_list_uri: https://groups.google.com/g/oauth-ruby
|
162
|
+
funding_uri: https://liberapay.com/pboling
|
133
163
|
rubygems_mfa_required: 'true'
|
134
|
-
post_install_message:
|
164
|
+
post_install_message:
|
135
165
|
rdoc_options: []
|
136
166
|
require_paths:
|
137
167
|
- lib
|
@@ -146,8 +176,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
146
176
|
- !ruby/object:Gem::Version
|
147
177
|
version: '0'
|
148
178
|
requirements: []
|
149
|
-
rubygems_version: 3.3.
|
150
|
-
signing_key:
|
179
|
+
rubygems_version: 3.3.20
|
180
|
+
signing_key:
|
151
181
|
specification_version: 4
|
152
182
|
summary: Enhance your VERSION! Sugar for Version modules.
|
153
183
|
test_files: []
|
metadata.gz.sig
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
$M�B��|G*��屽EM�.|.�X�0�m�,��{�s�p���Œ��d��J��XM)}-�P�� �q;�64��;z���%\�"�x��P�±�d6�I����X5�N�]-���.B�$�F���f*}���S8#�w��\3ũ4�A$���T�WM�>��:Q(�t�]�A�E��P�F�&oX���4�t{�sG�
|
data/sig/version_gem.rbs
DELETED