drg 0.6.0 → 0.7.0

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 79972e1a98ed795a5b79bd82df3776f21503cb0a
4
- data.tar.gz: 6fd465489ef30e2dde409df44d8d7b8d29065e94
3
+ metadata.gz: 0ff6322a9656b0257833c2751052ea6a48ed660d
4
+ data.tar.gz: ffbc2637332c3b297d443afd1e8e825d8fb9cc0d
5
5
  SHA512:
6
- metadata.gz: e600c88738d8de1a28b89e4ba88b6cfb9329b3caa1363ed7901dc36eaef19f1682c8f4f05abfdef93a743ac43eb8b7cd3a63237bbde8070d98413aa1fa723a35
7
- data.tar.gz: 0b50c62122cd9f959f5dc0fd0589feffeea2e9c552c98d927a25d9a8b718a5a54dbd96a6ab0a8499715e5517ad5e00e3102b26616f10787851215875fc082b0b
6
+ metadata.gz: 3333f0efac20212de8c076e397dd417179f94ad6ff57dc26f58d954a2d3139df6b212626936231e12234b069d41bbd9bdb59623b651584b83ed6732d83097bc7
7
+ data.tar.gz: 5604de606a2ae228850c93ecfea851566abd34e7651a87659a69c37f45dae7f638d0e3b4ff0dd85e71d616bbd49e4be4adaac8fe5b7b794d0cfe895517e9ad12
data/README.md CHANGED
@@ -24,15 +24,15 @@ rake drg:pin
24
24
  rake drg:pin:major
25
25
  rake drg:pin:minor
26
26
  rake drg:pin:patch
27
- rake drg:pin:latest_patch
28
- rake drg:pin:latest_minor
27
+ rake drg:pin:patch_latest
28
+ rake drg:pin:minor_latest
29
29
  rake drg:unpin
30
30
  ```
31
31
 
32
32
  ### drg:update
33
33
 
34
- DRG can update your outdated gems! It does this by checking for outdated gems, and then updating them one at time to the latest
35
- version. It then run your tests (with `rake`) and if your tests pass, the new version will be written to your Gemfile!
34
+ DRG loves updating gems! Run this command to check for outdated gems and try to update them to the latest available version.
35
+ Each outdated gem will be updated, then DRG will run your tests (with `rake`) and if your tests pass, the new version will be written to your Gemfile!
36
36
 
37
37
  ```bash
38
38
  rake drg:update
@@ -112,12 +112,30 @@ This can be combined with `bundle update` to quickly update all gems to the late
112
112
 
113
113
  ### drg:pin:major
114
114
 
115
- There is also a
115
+ Pins your gems at the major level:
116
116
 
117
117
  ```bash
118
118
  rake drg:pin:major
119
119
  ```
120
120
 
121
+ ### drg:pin:patch_latest
122
+
123
+ Updates the patch version for each outdated gem to the highest available version. This command should be run after `drg:pin` to ensure your gem versions are normalized.
124
+
125
+ ```bash
126
+ rake drg:pin:patch_latest #=> updates all gems in the Gemfile
127
+ rake drg:pin:patch_latest[<gem>] #=> updates only the specified <gem>
128
+ ```
129
+
130
+ ### drg:pin:minor_latest
131
+
132
+ Same as `patch_latest` except it updates the minor version to the latest
133
+
134
+ ```bash
135
+ rake drg:pin:minor_latest #=> updates all gems in the Gemfile
136
+ rake drg:pin:minor_latest[<gem>] #=> updates only the specified <gem>
137
+ ```
138
+
121
139
  ### drg:unpin
122
140
 
123
141
  Remove the versions from your Gemfile. Start fresh!
@@ -39,10 +39,9 @@ module DRG
39
39
  log %Q[Searching for latest #{type} version of "#{spec.name}" (currently #{spec.version.to_s}) ...]
40
40
  latest_version = public_send("latest_#{type}_version", spec.name, spec.version)
41
41
  if latest_version
42
- if ask(" * Do you want to update to version #{latest_version} (y/n)?").to_s.downcase == 'y'
43
- gemfile.update gem, latest_version
44
- updated_gems << gem.name
45
- end
42
+ log "Updating to version #{latest_version}"
43
+ gemfile.update gem, latest_version
44
+ updated_gems << gem.name
46
45
  else
47
46
  log %Q(No newer #{type} versions found)
48
47
  end
data/lib/drg/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module DRG
2
- VERSION = '0.6.0'.freeze
2
+ VERSION = '0.7.0'.freeze
3
3
  end
data/lib/tasks/drg.rake CHANGED
@@ -28,12 +28,12 @@ namespace :drg do
28
28
  end
29
29
 
30
30
  desc 'Pins all gems [or the requested gem] to the latest available patch version'
31
- task :latest_minor, [:gem_name] do |_, options|
31
+ task :minor_latest, [:gem_name] do |_, options|
32
32
  DRG::Tasks::ProgessivePinner.new(:minor).perform(options[:gem_name])
33
33
  end
34
34
 
35
35
  desc 'Pins all gems [or the requested gem] to the latest available minor version'
36
- task :latest_patch, [:gem_name] do |_, options|
36
+ task :patch_latest, [:gem_name] do |_, options|
37
37
  DRG::Tasks::ProgessivePinner.new(:patch).perform(options[:gem_name])
38
38
  end
39
39
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: drg
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.0
4
+ version: 0.7.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ryan Buckley