version_manager 1.0.0 → 1.0.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 4567a65cab744ad2b8e0cba5546a907616df5f56
4
- data.tar.gz: 90579a75079d72e8e2dbe1bc1dfb24e5a36bbfe1
3
+ metadata.gz: 412b45322d6ec083296e7ca8f88293980454ab1d
4
+ data.tar.gz: cd0e2cbf80b65a2dcbd3fe4d1dd4625b19945b21
5
5
  SHA512:
6
- metadata.gz: ba96ca3be67e8289b7b717b538bc997ea9409967bc5ac927c62ac852a586dc3de2492e8f53d02233c8693a3a52ffd8841a13e0eb0dad447e62027ca5f616bea5
7
- data.tar.gz: d29871302090e70b2cf670ae3070727f204fc2839010b108fa373636620503ca4af52dfd75b39e793b7be6218f0b80c0494941f8125c0f7d611324eb4822e5ef
6
+ metadata.gz: 721584f55433b4dd7960558bd235970b7b1a5d4d85b1057e17b370b07a01bd932d40279c29f23381d3d62488358b915c7d29eac275ad5faaa8262d68c0590bdd
7
+ data.tar.gz: a10cd1af8c5a1aea4174f985b98b7b0146963945cbbb0bbf9f592d4623854d17765fa2f44fed339a8cf12db8385242ed46a1a255061ddb75086378620991ab4f
data/README.md CHANGED
@@ -1,5 +1,8 @@
1
1
  # Version Manager
2
2
 
3
+ [![Build Status](https://travis-ci.org/tpbowden/version_manager.svg?branch=master)](https://travis-ci.org/tpbowden/version_manager) [![Code Climate](https://codeclimate.com/github/tpbowden/version_manager/badges/gpa.svg)](https://codeclimate.com/github/tpbowden/version_manager) [![Gem Version](https://badge.fury.io/rb/version_manager.svg)](https://badge.fury.io/rb/version_manager) [![Dependency Status](https://gemnasium.com/badges/github.com/tpbowden/version_manager.svg)](https://gemnasium.com/github.com/tpbowden/version_manager)
4
+
5
+
3
6
  Automatically manage version updates and tagging. The new version will be written to your version file,
4
7
  history file and as a tagged git commit.
5
8
 
@@ -66,3 +69,66 @@ The format git tags will be given after version has been updated. `%s` will be r
66
69
 
67
70
  The logger to use when printing info messages. By default this just logs the messages with no formatting to STDOUT.
68
71
  If you want to suppress logging you can just use `Logger.new "/dev/null"`
72
+
73
+ ## Example
74
+
75
+ Here is an example of what happens when you release a new version.
76
+
77
+ Given a version file `lib/my_gem/version.rb` which looks like this:
78
+
79
+ ```ruby
80
+
81
+ module MyGem
82
+ VERSION = "1.2.3"
83
+ end
84
+
85
+ ```
86
+
87
+ And a file `history.rdoc` which looks like this:
88
+
89
+ ```
90
+ * Some important work
91
+ * Some bug fixes
92
+ ```
93
+
94
+ And a rake task `tasks/release.rake` loaded by your Rakefile which looks like this:
95
+
96
+ ```ruby
97
+ require "version_manager/rake_task"
98
+
99
+ VersionManager::RakeTask.new do |config|
100
+ config.version_file = "lib/my_gem/version.rb"
101
+ config.version_constant = "MyGem::VERSION"
102
+ end
103
+ ```
104
+
105
+ You can create a new release by using one of the following command:
106
+
107
+ bundle exec rake release:major
108
+ bundle exec rake release:minor
109
+ bundle exec rake release:patch
110
+
111
+ When you do this 3 things will happen:
112
+
113
+ * The version file will be rewritten to contain the new version
114
+ ```ruby
115
+ module MyGem
116
+ VERSION = "2.0.0"
117
+ end
118
+
119
+ ```
120
+
121
+ * This history file will have a new line containing the new version and today's date
122
+ ```
123
+ == v2.0.0 (19 January 2017)
124
+
125
+ * Some important work
126
+ * Some bug fixes
127
+ ```
128
+
129
+ * The history and version files are both commited and tagged in git
130
+
131
+ The only things left to do then is push your new tag and commit then deploy the new release
132
+
133
+
134
+
@@ -1,3 +1,3 @@
1
1
  module VersionManager
2
- VERSION = "1.0.0".freeze
2
+ VERSION = "1.0.1".freeze
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: version_manager
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tom Bowden