bozo 0.3.6 → 0.3.7

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.
Files changed (3) hide show
  1. data/VERSION +1 -1
  2. data/lib/bozo/versioning/version.rb +12 -2
  3. metadata +3 -3
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.3.6
1
+ 0.3.7
@@ -5,10 +5,12 @@ module Bozo::Versioning
5
5
  # @param major [Integer]
6
6
  # @param minor [Integer]
7
7
  # @param patch [Integer]
8
- def initialize(major, minor, patch)
8
+ # @param extension [String]
9
+ def initialize(major, minor, patch, extension = nil)
9
10
  @major = major
10
11
  @minor = minor
11
12
  @patch = patch
13
+ @extension = extension
12
14
  end
13
15
 
14
16
  # Loads the version from the VERSION file
@@ -39,6 +41,10 @@ module Bozo::Versioning
39
41
  @patch
40
42
  end
41
43
 
44
+ def extension
45
+ @extension
46
+ end
47
+
42
48
  # Writes the version from the VERSION file
43
49
  def write_to_file
44
50
  File.open("VERSION", 'w') { |f| f << to_s }
@@ -52,7 +58,11 @@ module Bozo::Versioning
52
58
  end
53
59
 
54
60
  def to_s
55
- "#{@major}.#{@minor}.#{@patch}"
61
+ if @extension.nil?
62
+ "#{@major}.#{@minor}.#{@patch}"
63
+ else
64
+ "#{@major}.#{@minor}.#{@patch}-#{@extension}"
65
+ end
56
66
  end
57
67
 
58
68
  private
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bozo
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.6
4
+ version: 0.3.7
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -102,7 +102,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
102
102
  version: '0'
103
103
  segments:
104
104
  - 0
105
- hash: -3340202134502757491
105
+ hash: 2084281156218935817
106
106
  required_rubygems_version: !ruby/object:Gem::Requirement
107
107
  none: false
108
108
  requirements:
@@ -111,7 +111,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
111
111
  version: '0'
112
112
  segments:
113
113
  - 0
114
- hash: -3340202134502757491
114
+ hash: 2084281156218935817
115
115
  requirements: []
116
116
  rubyforge_project: bozo
117
117
  rubygems_version: 1.8.24