orats 0.3.0 → 0.3.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: 0a6c0e8dbdf731aa4475b5146b8e7816d42dd9db
4
- data.tar.gz: 2574c41229f58b27670a7d6caff9af1a6b4cc2a7
3
+ metadata.gz: a26044924f29339758058ce1fd44c070b101b3b1
4
+ data.tar.gz: d900ea0bea9f77b6ed79548f1454795ce11f1d1d
5
5
  SHA512:
6
- metadata.gz: e0629f4d2632b7697ea66880de7723762ac23714a110f770b4a221e22f7ac0d293eda935cc7e6a29b27179a3ca6dce448d1c5cdb7dfcc6d4b63e88f360c5cd3f
7
- data.tar.gz: 30eaf60bafff537a7ed5931d15715addde4e548955286fedb51258e6af4135d4f71d79530933e205c947b9e4e89df0c286f3f0d2ed0455ac90a10e48fc29d1a6
6
+ metadata.gz: 39b50b3fce6c70c9a660032088a79b61a76ffb8ebb9c05b217f310626063b44469029c9a9ebbde2d414590a49c70e1928800291f0c05e2a2b737b0c804fddb9a
7
+ data.tar.gz: 2ec9125e2e64d80cb301ecc0d97c75b2113b0811bf597ae6bc94206f4418ac4d026781d2f6741622ee9419381d949fb3d66d6216d742ca649e6111e264c9b7d9
data/README.md CHANGED
@@ -84,7 +84,7 @@ running `orats <command name> help` from your terminal. You can also type `orats
84
84
 
85
85
  - Delete the directory and optionally all data associated to it
86
86
  - `orats nuke <APP_PATH>`
87
- - Optionally takes `--skip-data [false]`
87
+ - Optionally takes: `--skip-data [false]`
88
88
 
89
89
  #### Why is it asking me for my development postgres password?
90
90
 
data/lib/orats/shell.rb CHANGED
@@ -66,7 +66,7 @@ module Orats
66
66
  end
67
67
  end
68
68
 
69
- def exit_if_cannot_cook
69
+ def can_cook?
70
70
  log_message 'shell', 'Checking for the cookbook system dependencies'
71
71
 
72
72
  has_knife = run('which knife', capture: true)
@@ -76,10 +76,11 @@ module Orats
76
76
  'Are you sure you have chef setup correctly?',
77
77
  'http://www.getchef.com/chef/install/`' if has_knife.empty?
78
78
 
79
-
80
79
  dependency_error 'Cannot access berkshelf',
81
80
  'Are you sure you have berkshelf installed correctly?',
82
81
  'You can install it by running `gem install berkshelf`' if has_berks.empty?
82
+
83
+ !has_knife.empty? && !has_berks.empty?
83
84
  end
84
85
 
85
86
  def exit_if_cannot_rails
@@ -90,6 +91,8 @@ module Orats
90
91
  dependency_error 'Cannot access rails',
91
92
  'Are you sure you have rails setup correctly?',
92
93
  'You can install it by running `gem install rails`' if has_rails.empty?
94
+
95
+ exit 1 if has_rails.empty?
93
96
  end
94
97
 
95
98
  def dependency_error(message, question, answer)
@@ -99,8 +102,6 @@ module Orats
99
102
  say_status 'answer', answer, :cyan
100
103
  puts '-'*80
101
104
  puts
102
-
103
- exit 1
104
105
  end
105
106
 
106
107
  def rails_template(command, flags = '', &block)
@@ -112,7 +113,7 @@ module Orats
112
113
  end
113
114
 
114
115
  def cook_app(app_path)
115
- exit_if_cannot_cook
116
+ return unless can_cook?
116
117
 
117
118
  @active_path = app_path
118
119
  rails_template 'cook'
data/lib/orats/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Orats
2
- VERSION = '0.3.0'
2
+ VERSION = '0.3.1'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: orats
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nick Janetakis