appmake 0.0.27 → 0.0.28
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/appmake/listeners/js.rb +20 -0
- data/lib/appmake/version.rb +1 -1
- data/lib/appmake.rb +1 -0
- metadata +2 -1
@@ -0,0 +1,20 @@
|
|
1
|
+
require "listen"
|
2
|
+
|
3
|
+
module Appmake
|
4
|
+
module Listeners
|
5
|
+
class Js
|
6
|
+
def initialize
|
7
|
+
listener = Listen.to "js", :filter => /\.js$/
|
8
|
+
listener.change(callback)
|
9
|
+
listener
|
10
|
+
end
|
11
|
+
|
12
|
+
def callback
|
13
|
+
Proc.new do |modified, added, removed|
|
14
|
+
puts "=> rebuilding JS"
|
15
|
+
system("node bin/compile_templates.js")
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
19
|
+
end
|
20
|
+
end
|
data/lib/appmake/version.rb
CHANGED
data/lib/appmake.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: appmake
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.28
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -91,6 +91,7 @@ files:
|
|
91
91
|
- appmake.gemspec
|
92
92
|
- bin/appmake
|
93
93
|
- lib/appmake.rb
|
94
|
+
- lib/appmake/listeners/js.rb
|
94
95
|
- lib/appmake/version.rb
|
95
96
|
- templates/bin/compile_templates.js.tt
|
96
97
|
- templates/css/app.scss.tt
|