guard-rails 0.3.1 → 0.3.2
Sign up to get free protection for your applications and to get access to all the features.
- data/Rakefile +7 -0
- data/VERSION +1 -1
- data/lib/guard/rails/runner.rb +5 -2
- metadata +4 -4
data/Rakefile
CHANGED
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.3.
|
1
|
+
0.3.2
|
data/lib/guard/rails/runner.rb
CHANGED
@@ -7,6 +7,7 @@ module Guard
|
|
7
7
|
attr_reader :options
|
8
8
|
|
9
9
|
def initialize(options)
|
10
|
+
@env = ENV
|
10
11
|
@options = options
|
11
12
|
end
|
12
13
|
|
@@ -36,6 +37,8 @@ module Guard
|
|
36
37
|
def build_rails_command
|
37
38
|
return %{#{options[:CLI]} --pid #{pid_file}} if options[:CLI]
|
38
39
|
|
40
|
+
@env['RAILS_ENV'] = options[:environment] if options[:environment]
|
41
|
+
|
39
42
|
rails_options = [
|
40
43
|
options[:daemon] ? '-d' : nil,
|
41
44
|
options[:debugger] ? '-u' : nil,
|
@@ -50,7 +53,7 @@ module Guard
|
|
50
53
|
]
|
51
54
|
|
52
55
|
# omit env when use zeus
|
53
|
-
rails_runner = options[:zeus] ? "zeus #{zeus_options.join(' ')}" : "
|
56
|
+
rails_runner = options[:zeus] ? "zeus #{zeus_options.join(' ')}" : "rails server"
|
54
57
|
|
55
58
|
%{#{rails_runner} #{rails_options.join(' ')}}
|
56
59
|
end
|
@@ -69,7 +72,7 @@ module Guard
|
|
69
72
|
|
70
73
|
private
|
71
74
|
def run_rails_command!
|
72
|
-
|
75
|
+
Process.spawn @env, build_rails_command
|
73
76
|
end
|
74
77
|
|
75
78
|
def has_pid?
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: guard-rails
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.2
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2013-02-
|
13
|
+
date: 2013-02-25 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: guard
|
@@ -113,7 +113,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
113
113
|
version: '0'
|
114
114
|
segments:
|
115
115
|
- 0
|
116
|
-
hash: -
|
116
|
+
hash: -1138378387217112587
|
117
117
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
118
118
|
none: false
|
119
119
|
requirements:
|
@@ -122,7 +122,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
122
122
|
version: '0'
|
123
123
|
segments:
|
124
124
|
- 0
|
125
|
-
hash: -
|
125
|
+
hash: -1138378387217112587
|
126
126
|
requirements: []
|
127
127
|
rubyforge_project: guard-rails
|
128
128
|
rubygems_version: 1.8.23
|