release-notes 1.1.0 → 1.1.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
  SHA256:
3
- metadata.gz: 1f57251370fff06c63ccbbb0719638cf769a0f93e689670797ec7a9bbce6cecc
4
- data.tar.gz: 59ea08dcca6b490195ba032e4786a4acc4062ab6883e291388975cf9681ef7c6
3
+ metadata.gz: d55b65f398efbef833f63bbc1fc5bf86bc062e9ce3d07658342f293565d182e5
4
+ data.tar.gz: e2f6b3abce7ddbd520d54375dac4c09969841e96f70de7b6541fb58d103288b9
5
5
  SHA512:
6
- metadata.gz: faca9e5eda060af2c513130e711c178ef8a698b7bd91285730c4913eb0467657011ad39419d947de68341f7b7b2bdd3869a6314ffe86844b25dff028177c2e81
7
- data.tar.gz: b72a541e60752ec2ece0badabcacc18014feebd9d20bea2dd3db4a31f50f73f5d7453c14e9d3de0a3fae0f2a96bf5a8efd3c6fc3e33d7e13ea37b4bf7cd17287
6
+ metadata.gz: eb2dee824dbcf7936176f18e6557d462c3a9ba6ac6b8e702586a9801597a98b318b1446310949d4b8c1ee31e84fb63e0587c1708cf760d203efeefe978ab74ed
7
+ data.tar.gz: 2ccb891af0e2a54def2237ab47f9f145d2967fad58dd888882734850a5dc03b7a43beca78a61df078a6bd8e29c0d5b8fea66518ab6884c2694b6a3c75f8dd566
data/README.md CHANGED
@@ -50,7 +50,7 @@ After you install Release::Notes, generate the intializer file:
50
50
  $ rails generate release:notes:install
51
51
 
52
52
  # non-rails
53
- $ bundle exec release:notes:install
53
+ $ bundle exec rake release:notes:install
54
54
  ```
55
55
 
56
56
  ## Configure
@@ -126,35 +126,20 @@ check out the following links
126
126
 
127
127
  ### Deploying with Capistrano
128
128
 
129
- If using Rails, a rake task is included and would be best utilized within your deploy script.
130
-
131
- If not on rails, but using rake, you can easily craft your own rake task. At the very least calling
132
-
133
- ```ruby
134
- Release::Notes.generate
135
- ```
136
-
137
- is the only instance that needs to be instantiated and invoked.
138
-
139
- A sample capistrano production file might look something like this:
129
+ A sample capistrano rake task might look like:
140
130
 
141
131
  ```ruby
142
132
  # config/deploy/production.rb
143
- server 'the_name_for_my_server', user: 'deploy', roles: %w{app web}
144
-
145
- set :application, 'my_app'
146
- set :deploy_to, '/var/www/my_app'
147
-
148
-
149
133
  namespace :deploy do
150
134
  before :starting, :update_release_notes
151
135
 
152
136
  task :update_release_notes do
153
137
  # use the binstub
154
138
  sh 'bin/release-notes"'
155
- # run a second task that generates an auto commit
156
- # this would be created by you
157
- sh 'bin/rake "release_notes:commit"'
139
+
140
+ # Then check in your release notes with a commit
141
+ sh "git commit -am 'Release to production #{Time.zone.now}'"
142
+ sh "git push origin master"
158
143
  end
159
144
  end
160
145
  ```
@@ -162,17 +147,7 @@ end
162
147
  Useful information can be found here regarding the
163
148
  [capistrano flow](http://capistranorb.com/documentation/getting-started/flow/).
164
149
 
165
- As you can see above, it's suggested that after generating your release notes you would
166
- run an automated commit with a rake task like:
167
-
168
- ```ruby
169
- # lib/tasks/commit.rake
170
- `git commit -am "Release to production #{Time.zone.now}"`
171
- `git push origin master`
172
- ```
173
-
174
- From there, make sure you tag your release after the deploy script runs so that your tag
175
- includes this last commit.
150
+ **From there, make sure you tag your releases**
176
151
 
177
152
  ## Note
178
153
 
@@ -4,15 +4,19 @@
4
4
  $LOAD_PATH.unshift File.join(File.dirname(__FILE__), "..", "lib")
5
5
 
6
6
  require "release/notes"
7
- config_file = "./config/initializers/release_notes.rb"
7
+
8
+ rails_config_file = "./config/initializers/release_notes.rb"
9
+ config_file = "./config/release_notes.rb"
10
+
11
+ file = File.exist?(rails_config_file) ? rails_config_file : config_file
8
12
 
9
13
  begin
10
- require config_file
14
+ require file
11
15
  warn "=> Generating release notes..."
12
16
  Release::Notes.generate
13
17
  warn "=> Done!"
14
18
  rescue LoadError
15
- warn "=> Missing config/initializers/release_notes.rb"
19
+ warn "=> Missing release_notes.rb configuration file"
16
20
  rescue SignalException => e
17
21
  # We might receive SIGTERM before our signal handler is installed.
18
22
  if Signal.signame(e.signo) == "TERM"
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Release
4
4
  module Notes
5
- VERSION = "1.1.0"
5
+ VERSION = "1.1.1"
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: release-notes
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.0
4
+ version: 1.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Drew Monroe