fangorn 0.0.11 → 0.0.12

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/fangorn/js.rb +11 -2
  3. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 0c8e936a9c3690c8b41efe7796129b7fafa5b9bb
4
- data.tar.gz: aa2c35b7f30afbb85386d55c22f44cc19efca8b7
3
+ metadata.gz: 3e37c359b1b7105b3fdefbfa0dd8325622ba0f0d
4
+ data.tar.gz: 2d73dcb1515a223b029a1d1548752f47e0000cc2
5
5
  SHA512:
6
- metadata.gz: dd1c2079d6f4b971c3d183d78d71f7337d13477f44d460a6f90fea4ee38eaf4f821dca9f8eb0e4218c469ab2f93a246b370fabfcd1eea914350a13670a32c989
7
- data.tar.gz: e1d4d4b257e5a53946baeba48b4415e7b3047472591d72c00216ccd160b5c95a5562aa1d14adb8958b9adaf1544214bf6f16c52e01979a9de31409bffcd67055
6
+ metadata.gz: 91fa471cf72cd3a5a4b4a836071a7ccba0d542c04ef37bbc6881ca29c35ba5566a6c764982a95c6f199cab6c2c3d42faebf65c2c886b68189c792e5f81b81d18
7
+ data.tar.gz: 8a999110a5d9de7ec580edc7c07717bda4fb44ce8b3f1a0677d75a036f778e48eb97a9f4b29aa9c14e55f153e2a4e6dccd8fd1e311811863a90522f6c20886e4
data/lib/fangorn/js.rb CHANGED
@@ -25,8 +25,17 @@ module Fangorn
25
25
  end
26
26
  end
27
27
 
28
- f.write contents
29
- f.puts if Output::dist?
28
+ if Output::dist?
29
+ open("| uglifyjs", 'w+') do |uglifyjs|
30
+ uglifyjs.write contents
31
+ uglifyjs.close_write
32
+ f.puts uglifyjs.read
33
+ end
34
+
35
+ else
36
+ f.write contents
37
+ end
38
+
30
39
  end
31
40
  end
32
41
  def application_js
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fangorn
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.11
4
+ version: 0.0.12
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ryan Calhoun
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-12-11 00:00:00.000000000 Z
11
+ date: 2017-02-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: listen