npm-pipeline-rails 1.5.0.pre.1 → 1.5.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/HISTORY.md +10 -1
- data/README.md +5 -0
- data/lib/npm-pipeline-rails/railtie.rb +3 -2
- data/lib/npm-pipeline-rails/version.rb +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: eb96738c4e2c453cdf4135d1c3a26c3b09580103
|
4
|
+
data.tar.gz: 4e88f6fac09276cdf1de3c5a24c5b25563ca11da
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4db7512df7bf8d65407738e419d44572c120f9f50c350a623c1f7a235109dc5149b25396e81f365373a724249dd2ecc198d5aef5981d05acc75d69ad1b594cb1
|
7
|
+
data.tar.gz: 4f3af06963eba4a6ffcef12b051c891ae2085ec348f7669bae91ad7f3e31f52c72dd033331e6d785459c6191dde31eecddfc48418470225609139d7d3f5e9e45
|
data/HISTORY.md
CHANGED
@@ -1,3 +1,10 @@
|
|
1
|
+
## [v1.5.0]
|
2
|
+
> May 24, 2016
|
3
|
+
|
4
|
+
- [#7] - Add a `config.npm.enable_watch` flag. ([@jasontorres])
|
5
|
+
|
6
|
+
[v1.5.0]: https://github.com/rstacruz/npm-pipeline-rails/compare/v1.4.0...v1.5.0
|
7
|
+
|
1
8
|
## [v1.4.0]
|
2
9
|
> Apr 20, 2016
|
3
10
|
|
@@ -55,6 +62,8 @@
|
|
55
62
|
|
56
63
|
[v1.0.0]: https://github.com/rstacruz/npm-pipeline-rails/tree/v1.0.0
|
57
64
|
[#1]: https://github.com/rstacruz/npm-pipeline-rails/issues/1
|
58
|
-
[@victorsolis]: https://github.com/victorsolis
|
59
65
|
[#3]: https://github.com/rstacruz/npm-pipeline-rails/issues/3
|
60
66
|
[#4]: https://github.com/rstacruz/npm-pipeline-rails/issues/4
|
67
|
+
[#7]: https://github.com/rstacruz/npm-pipeline-rails/issues/7
|
68
|
+
[@jasontorres]: https://github.com/jasontorres
|
69
|
+
[@victorsolis]: https://github.com/victorsolis
|
data/README.md
CHANGED
@@ -80,6 +80,11 @@ npm-pipeline-rails provides these configuration options:
|
|
80
80
|
# These are defaults; in most cases, you don't need to configure anything.
|
81
81
|
|
82
82
|
Rails.application.configure do
|
83
|
+
# Enables npm_pipeline_rails's invocation of `watch` commands.
|
84
|
+
# If `true`, watch commands will be ran alongside Rails's server.
|
85
|
+
# Defaults to true in development.
|
86
|
+
config.npm.enable_watch = Rails.env.development?
|
87
|
+
|
83
88
|
# Command to install dependencies
|
84
89
|
config.npm.install = ['npm install']
|
85
90
|
|
@@ -6,7 +6,7 @@ module NpmPipelineRails
|
|
6
6
|
module_function
|
7
7
|
|
8
8
|
def log(str)
|
9
|
-
|
9
|
+
::Rails.logger.debug "[npm-pipeline-rails] #{str}"
|
10
10
|
end
|
11
11
|
|
12
12
|
def do_system(commands)
|
@@ -33,6 +33,7 @@ module NpmPipelineRails
|
|
33
33
|
|
34
34
|
class Railtie < ::Rails::Railtie
|
35
35
|
config.npm = ActiveSupport::OrderedOptions.new
|
36
|
+
config.npm.enable_watch = ::Rails.env.development?
|
36
37
|
config.npm.build = ['npm run build']
|
37
38
|
config.npm.watch = ['npm run start']
|
38
39
|
config.npm.install = ['npm install']
|
@@ -50,7 +51,7 @@ module NpmPipelineRails
|
|
50
51
|
end
|
51
52
|
|
52
53
|
initializer 'npm_pipeline.watch' do |app|
|
53
|
-
if
|
54
|
+
if app.config.npm.enable_watch && ::Rails.const_defined?(:Server)
|
54
55
|
Utils.do_system app.config.npm.install
|
55
56
|
[*app.config.npm.watch].each do |cmd|
|
56
57
|
Utils.background(cmd) { Utils.do_system [cmd] }
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: npm-pipeline-rails
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.5.0
|
4
|
+
version: 1.5.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Rico Sta. Cruz
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-05-
|
11
|
+
date: 2016-05-24 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: railties
|
@@ -144,9 +144,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
144
144
|
version: '0'
|
145
145
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
146
146
|
requirements:
|
147
|
-
- - "
|
147
|
+
- - ">="
|
148
148
|
- !ruby/object:Gem::Version
|
149
|
-
version:
|
149
|
+
version: '0'
|
150
150
|
requirements: []
|
151
151
|
rubyforge_project:
|
152
152
|
rubygems_version: 2.5.1
|