qb 0.1.65 → 0.1.66
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/qb/package/version.rb +24 -0
- data/lib/qb/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 312cc71f379e2befa17609db30bc330bb679c458
|
4
|
+
data.tar.gz: df361529245785a5e01d13fb12a5b81677040d0e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8009084bc7a5b70e9fa745181382148332d7724c935abf1d805078828994ff9d0a682d1cceb91cb79d03f4e49a9747d3431a8711b1a3ad8f47b3868f6242bb6e
|
7
|
+
data.tar.gz: 1bd90fcdac891b412824ec25f26b34b3683234ea990a90b03f6a31d05ee7bdbd38f7333511a676707b1301bfded4a3184ef9c6bb743ddce9e28e91c32aa21236
|
data/lib/qb/package/version.rb
CHANGED
@@ -49,6 +49,18 @@ module QB
|
|
49
49
|
end
|
50
50
|
end
|
51
51
|
|
52
|
+
attr_reader :raw,
|
53
|
+
:major,
|
54
|
+
:minor,
|
55
|
+
:patch,
|
56
|
+
:prerelease,
|
57
|
+
:build,
|
58
|
+
:release,
|
59
|
+
:level,
|
60
|
+
:is_release,
|
61
|
+
:is_dev,
|
62
|
+
:is_rc
|
63
|
+
|
52
64
|
# Construct a new Version
|
53
65
|
def initialize raw:, major:, minor:, patch:, prerelease:, build:, release:
|
54
66
|
@raw = raw
|
@@ -66,6 +78,18 @@ module QB
|
|
66
78
|
@is_rc = @prerelease[0] == 'rc'
|
67
79
|
end
|
68
80
|
|
81
|
+
def release?
|
82
|
+
@is_release
|
83
|
+
end
|
84
|
+
|
85
|
+
def dev?
|
86
|
+
@is_dev
|
87
|
+
end
|
88
|
+
|
89
|
+
def rc?
|
90
|
+
@is_rc
|
91
|
+
end
|
92
|
+
|
69
93
|
# dump all instance variables into a hash
|
70
94
|
def to_h
|
71
95
|
instance_variables.map {|var|
|
data/lib/qb/version.rb
CHANGED