haml_coffee_assets 1.16.0 → 1.19.0

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
- SHA1:
3
- metadata.gz: c69a78d37958a5eb8100e64f3ce99aa845534740
4
- data.tar.gz: 064a19166880278d3cc92fc1794d7c260310ead7
2
+ SHA256:
3
+ metadata.gz: d33fc6ea36cd0382ca9b29dec3e84f90dab547d5b8ddc39b66c87220ca5cc75c
4
+ data.tar.gz: 4810434b00ae506af8686f6d2d7da6519b20ccb00d309ac32cb951d8ee31b186
5
5
  SHA512:
6
- metadata.gz: 70e76fc9f0b9e573cf51763b1a266ece1fefab977a7efdccb8c92a90ba310931d693683ea6b8a47266b91e7c13324596140485e39565d71f1d775e206332896d
7
- data.tar.gz: 5a4249bcd796aea65aba75a2b40983f412e23b850ee86416f986e278704ccd4522313203987c83f4e1578970b031e3414c1bfda84deb8f898bb499776960508f
6
+ metadata.gz: 447e637da82634f30a4a459665dbc22addfe63d285c1590bdb98db948516039a72082b7f364f73861293cc52f16edaf9e54bcb3e6d6295dacda1c96426d7ef8d
7
+ data.tar.gz: 996fc5d75d6782cfd9379f1f99ce36bba561982d43deff7ef8fcf921c258d91668c697446b7fd54e9bd0800d7b626c7a2494a74a13a4965194aa03a811495c22
data/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # Haml Coffee Assets [![Build Status](https://secure.travis-ci.org/netzpirat/haml_coffee_assets.png)](http://travis-ci.org/netzpirat/haml_coffee_assets)
1
+ # Haml Coffee Assets [![Build Status](https://secure.travis-ci.org/emilioforrer/haml_coffee_assets.png)](http://travis-ci.org/emilioforrer/haml_coffee_assets)
2
2
 
3
3
  Haml Coffee Assets compiles [Haml Coffee](https://github.com/netzpirat/haml-coffee) templates in the Rails 3.1 asset
4
4
  pipeline, so you can use them as JavaScript templates in your JavaScript heavy Rails application. Server-side rendering
@@ -48,8 +48,7 @@ group :assets do
48
48
  gem 'execjs'
49
49
  end
50
50
  ```
51
-
52
- And require the `hamlcoffee.js` in your `app/assets/javascripts/templates/context.js.coffee`:
51
+ (note that Rails 4.0 [removed the assets group](https://github.com/rails/rails/commit/49c4af43ec5819d8f5c1a91f9b84296c927ce6e7) from Gemfile and so you don't need that line) and require the `hamlcoffee.js` in your `app/assets/javascripts/templates/context.js.coffee`:
53
52
 
54
53
  ```coffeescript
55
54
  #= require hamlcoffee
@@ -60,7 +59,7 @@ If you're using AMD support then you do not need to include the above helper, si
60
59
  This provides the default escaping and the global context functions. Read more about it in the configuration section
61
60
  below.
62
61
 
63
- Please have a look at the [CHANGELOG](https://github.com/netzpirat/haml_coffee_assets/blob/master/CHANGELOG.md) when
62
+ Please have a look at the [CHANGELOG](https://github.com/emilioforrer/haml_coffee_assets/blob/master/CHANGELOG.md) when
64
63
  upgrading to a newer Haml Coffee Assets version.
65
64
 
66
65
  If you want to use Haml Coffee with Sinatra, please have a look at the
@@ -95,7 +94,7 @@ removed.
95
94
 
96
95
  When you give your templates the extension `.jst.hamlc`, Haml Coffee Assets will only generate the template function,
97
96
  which then in turn will be further processed by the
98
- [Sprocket JST processor](https://github.com/sstephenson/sprockets/blob/master/lib/sprockets/jst_processor.rb). Because
97
+ [Sprocket JST processor](https://github.com/rails/sprockets/blob/master/lib/sprockets/jst_processor.rb). Because
99
98
  Haml Coffee Assets will not generate the template, you can't use the AMD support, template name filter and the JST
100
99
  namespace definition is more cumbersome compared to the Haml Coffee template generation.
101
100
 
@@ -409,7 +408,7 @@ App.globalTemplateContext = (locals) -> HAML.extend({}, {
409
408
  }, locals)
410
409
  ```
411
410
 
412
- Please have a look at the wiki for [further examples](https://github.com/netzpirat/haml_coffee_assets/wiki) on how to
411
+ Please have a look at the wiki for [further examples](https://github.com/emilioforrer/haml_coffee_assets/wiki) on how to
413
412
  use the global context.
414
413
 
415
414
  ### Customize the tag lists
@@ -457,7 +456,7 @@ to, you can set custom functions for:
457
456
  * config.hamlcoffee.customSucceed
458
457
  * config.hamlcoffee.customPrecede
459
458
 
460
- You can see the [default implementation](https://github.com/netzpirat/haml_coffee_assets/blob/master/vendor/assets/javascripts/hamlcoffee.js.coffee.erb)
459
+ You can see the [default implementation](https://github.com/emilioforrer/haml_coffee_assets/blob/master/vendor/assets/javascripts/hamlcoffee.js.coffee.erb)
461
460
  and the [Haml Coffee documentation](https://github.com/netzpirat/haml-coffee#custom-helper-function-options)
462
461
  for more information about each helper function.
463
462
 
@@ -515,16 +514,16 @@ example.
515
514
 
516
515
  ## Author
517
516
 
518
- Developed by Michael Kessler, [mksoft.ch](https://mksoft.ch).
517
+ Developed by Michael Kessler, [FlinkFinger](http://www.flinkfinger.com).
519
518
 
520
- If you like Haml Coffee Assets, you can watch the repository at [GitHub](https://github.com/netzpirat/haml_coffee_assets)
519
+ If you like Haml Coffee Assets, you can watch the repository at [GitHub](https://github.com/emilioforrer/haml_coffee_assets)
521
520
  and follow [@netzpirat](https://twitter.com/#!/netzpirat) on Twitter for project updates.
522
521
 
523
522
  ## Development
524
523
 
525
- * Issues and feature request hosted at [GitHub Issues](https://github.com/netzpirat/haml_coffee_assets/issues).
526
- * Documentation hosted at [RubyDoc](http://rubydoc.info/github/netzpirat/haml_coffee_assets/master/frames).
527
- * Source hosted at [GitHub](https://github.com/netzpirat/haml_coffee_assets).
524
+ * Issues and feature request hosted at [GitHub Issues](https://github.com/emilioforrer/haml_coffee_assets/issues).
525
+ * Documentation hosted at [RubyDoc](http://rubydoc.info/github/emilioforrer/haml_coffee_assets/master/frames).
526
+ * Source hosted at [GitHub](https://github.com/emilioforrer/haml_coffee_assets).
528
527
 
529
528
  Pull requests are very welcome! Please try to follow these simple rules if applicable:
530
529
 
@@ -549,8 +548,8 @@ Please try to follow these simple rules:
549
548
 
550
549
  ## Contributors
551
550
 
552
- See the [CHANGELOG](https://github.com/netzpirat/haml_coffee_assets/blob/master/CHANGELOG.md) and the GitHub list of
553
- [contributors](https://github.com/netzpirat/haml_coffee_assets/contributors).
551
+ See the [CHANGELOG](https://github.com/emilioforrer/haml_coffee_assets/blob/master/CHANGELOG.md) and the GitHub list of
552
+ [contributors](https://github.com/emilioforrer/haml_coffee_assets/contributors).
554
553
 
555
554
  ## Acknowledgement
556
555
 
@@ -2,7 +2,6 @@
2
2
 
3
3
  require 'pathname'
4
4
 
5
- require 'tilt'
6
5
  require 'sprockets'
7
6
  require 'execjs'
8
7
 
@@ -11,7 +10,7 @@ require 'haml_coffee_assets/configuration'
11
10
  require 'haml_coffee_assets/compiler'
12
11
  require 'haml_coffee_assets/version'
13
12
 
14
- require 'haml_coffee_assets/tilt/template_handler'
13
+ require 'haml_coffee_assets/transformer'
15
14
 
16
15
  if defined?(Rails) && Rails.version >= '3.0.0'
17
16
  require 'rails'
@@ -19,7 +18,7 @@ if defined?(Rails) && Rails.version >= '3.0.0'
19
18
  require 'haml_coffee_assets/action_view/patches'
20
19
  else
21
20
  require 'sprockets/engines'
22
- Sprockets.register_engine '.hamlc', ::HamlCoffeeAssets::Tilt::TemplateHandler
21
+ Sprockets.register_engine '.hamlc', ::HamlCoffeeAssets::Transformer
23
22
  end
24
23
 
25
24
  # Main Haml Coffee Assets module with
@@ -1,36 +1,44 @@
1
- # Monkey patches for rails to support our template engine.
2
- # Hopefully these fixes will make it into rails or we find a
3
- # better way to avoid this.
4
- #
5
- # TODO: Don't monkey patch rails
6
-
7
1
  # See patch notes inline
8
- class ::ActionView::Template
2
+ module HamlCoffeeAssets::ActionView
3
+ module Patches
4
+ def self.included(base)
5
+ base.send :include, InstanceMethods
6
+ base.send :alias_method, :handle_render_error_without_patch, :handle_render_error
7
+ base.send :alias_method, :handle_render_error, :handle_render_error_with_patch
8
+ end
9
9
 
10
- # Patch, it's almost exaclty the same with a small tweak
11
- def handle_render_error(view, e) #:nodoc:
12
- if e.is_a?(::ActionView::Template::Error)
13
- e.sub_template_of(self)
14
- raise e
15
- else
16
- assigns = view.respond_to?(:assigns) ? view.assigns : {}
17
- template = self
10
+ module InstanceMethods
11
+ # Patch, it's almost exaclty the same with a small tweak
12
+ def handle_render_error_with_patch(view, e) #:nodoc:
13
+ if e.is_a?(::ActionView::Template::Error)
14
+ e.sub_template_of(self)
15
+ raise e
16
+ else
17
+ assigns = view.respond_to?(:assigns) ? view.assigns : {}
18
+ template = self
18
19
 
19
- # Here's the patch: if the javascript runtime throws an error
20
- # during compilation, we get to this handler but our view
21
- # doesn't have a lookup_context - thus throwing a very hard
22
- # to debug error in Template#refresh. To circumvent, ensure the
23
- # view responds to lookup_context before refreshing.
24
- if view.respond_to?(:lookup_context) and template.source.nil?
25
- template = refresh(view)
26
- template.encode!
27
- end
20
+ # Here's the patch: if the javascript runtime throws an error
21
+ # during compilation, we get to this handler but our view
22
+ # doesn't have a lookup_context - thus throwing a very hard
23
+ # to debug error in Template#refresh. To circumvent, ensure the
24
+ # view responds to lookup_context before refreshing.
25
+ if view.respond_to?(:lookup_context) and template.source.nil?
26
+ template = refresh(view)
27
+ template.encode! if template.respond_to?(:encode!)
28
+ end
28
29
 
29
- if Rails::VERSION::STRING < "4"
30
- raise ::ActionView::Template::Error.new(template, assigns, e)
31
- else
32
- raise ::ActionView::Template::Error.new(template, e)
30
+ if ::Rails::VERSION::STRING < "4"
31
+ raise ::ActionView::Template::Error.new(template, assigns, e)
32
+ elsif ::Rails::VERSION::STRING < "5.1"
33
+ raise ::ActionView::Template::Error.new(template, e)
34
+ else
35
+ raise ::ActionView::Template::Error.new(template)
36
+ end
37
+ end
33
38
  end
34
39
  end
40
+
35
41
  end
36
42
  end
43
+
44
+ ::ActionView::Template.send :include, HamlCoffeeAssets::ActionView::Patches if defined? ::ActionView::Template
@@ -1,4 +1,5 @@
1
1
  require "action_view"
2
+ require 'action_view/template/resolver'
2
3
 
3
4
  module HamlCoffeeAssets
4
5
  module ActionView
@@ -7,10 +8,14 @@ module HamlCoffeeAssets
7
8
  # in it would normally be a fallback for all formats.
8
9
  #
9
10
  class Resolver < ::ActionView::FileSystemResolver
10
- def find_templates(name, prefix, partial, details)
11
+ def find_templates(name, prefix, partial, details, outside_app_allowed = false)
11
12
  if details[:formats].include?(:html)
12
13
  clear_cache if ::Rails.env == "development"
13
- super
14
+ if ::Rails::VERSION::STRING < "4.2.5.1"
15
+ super(name, prefix, partial, details)
16
+ else
17
+ super(name, prefix, partial, details, outside_app_allowed)
18
+ end
14
19
  else
15
20
  []
16
21
  end
@@ -77,10 +77,18 @@ module HamlCoffeeAssets
77
77
  end
78
78
  end
79
79
 
80
- next unless app.assets
80
+ config.assets.configure do |env|
81
+ if env.respond_to?(:register_transformer)
82
+ env.register_mime_type 'text/hamlc', extensions: ['.hamlc']
83
+ env.register_transformer 'text/hamlc', 'application/javascript', ::HamlCoffeeAssets::Transformer
84
+ end
81
85
 
82
- # Register Tilt template (for Sprockets)
83
- app.assets.register_engine '.hamlc', ::HamlCoffeeAssets::Tilt::TemplateHandler
86
+ if env.respond_to?(:register_engine)
87
+ args = ['.hamlc', ::HamlCoffeeAssets::Transformer]
88
+ args << { mime_type: 'text/hamlc', silence_deprecation: true } if Sprockets::VERSION.start_with?('3')
89
+ env.register_engine(*args)
90
+ end
91
+ end
84
92
  end
85
93
 
86
94
  end
@@ -0,0 +1,33 @@
1
+ # coding: UTF-8
2
+
3
+ module HamlCoffeeAssets
4
+ # Haml Coffee Sprockets processor
5
+ #
6
+ class Transformer
7
+ def initialize(filename, &block)
8
+ @filename = filename
9
+ @source = block.call
10
+ end
11
+
12
+ def render(context, empty_hash_wtf)
13
+ self.class.run(@filename, @filename, @source, context)
14
+ end
15
+
16
+ def self.run(filename, name, source, context)
17
+ jst = !!(filename =~ /\.jst\.hamlc(?:\.|$)/)
18
+ name = HamlCoffeeAssets.config.name_filter.call(name) if HamlCoffeeAssets.config.name_filter && !jst
19
+
20
+ HamlCoffeeAssets::Compiler.compile(name, source, !jst)
21
+ end
22
+
23
+ def self.call(input)
24
+ filename = input[:filename]
25
+ name = input[:name]
26
+ source = input[:data]
27
+ context = input[:environment].context_class.new(input)
28
+
29
+ result = run(filename, name, source, context)
30
+ context.metadata.merge(data: result)
31
+ end
32
+ end
33
+ end
@@ -1,5 +1,5 @@
1
1
  # coding: UTF-8
2
2
 
3
3
  module HamlCoffeeAssets
4
- VERSION = '1.16.0' unless defined?(HamlCoffeeAssets::VERSION)
4
+ VERSION = '1.19.0' unless defined?(HamlCoffeeAssets::VERSION)
5
5
  end
data/lib/js/hamlcoffee.js CHANGED
@@ -454,7 +454,7 @@ require.define("/haml-coffee.coffee",function(require,module,exports,__dirname,_
454
454
  indent = require('./util/text').indent;
455
455
 
456
456
  module.exports = HamlCoffee = (function() {
457
- HamlCoffee.VERSION = '1.13.5';
457
+ HamlCoffee.VERSION = '1.13.6';
458
458
 
459
459
  function HamlCoffee(options) {
460
460
  var segment, segments, _base, _base1, _base10, _base11, _base12, _base13, _base2, _base3, _base4, _base5, _base6, _base7, _base8, _base9, _i, _len;
@@ -671,6 +671,7 @@ require.define("/haml-coffee.coffee",function(require,module,exports,__dirname,_
671
671
  result = line.match(/^(\s*)(.*)/);
672
672
  ws = result[1];
673
673
  expression = result[2];
674
+ this.currentIndent = ws.length;
674
675
  if (/^\s*$/.test(line)) {
675
676
  continue;
676
677
  }
@@ -680,7 +681,7 @@ require.define("/haml-coffee.coffee",function(require,module,exports,__dirname,_
680
681
  expression += ' ' + attributes.match(/^\s*(.*?)(\s+\|\s*)?$/)[1];
681
682
  this.lineNumber++;
682
683
  }
683
- while (/^-#/.test(expression) && RegExp("^\\s{" + (this.previousIndent + (this.tabSize || 2)) + "}").test(lines[0]) && lines.length > 0) {
684
+ while (/^-#/.test(expression) && RegExp("^\\s{" + (this.currentIndent + (this.tabSize || 2)) + "}").test(lines[0]) && lines.length > 0) {
684
685
  lines.shift();
685
686
  this.lineNumber++;
686
687
  }
@@ -691,7 +692,6 @@ require.define("/haml-coffee.coffee",function(require,module,exports,__dirname,_
691
692
  this.lineNumber++;
692
693
  }
693
694
  }
694
- this.currentIndent = ws.length;
695
695
  if (this.indentChanged()) {
696
696
  this.updateTabSize();
697
697
  this.updateBlockLevel();
@@ -48,7 +48,7 @@ define ->
48
48
  #
49
49
  findAndPreserve: (text) ->
50
50
  tags = '<%= ::HamlCoffeeAssets.config.preserveTags %>'.split(',').join('|')
51
- text = text.replace(/\r/g, '').replace ///<(#{ tags })>([\s\S]*?)<\/\1>/// g, (str, tag, content) ->
51
+ text = text.replace(/\r/g, '').replace ///<(#{ tags })>([\s\S]*?)<\/\1>///g, (str, tag, content) ->
52
52
  "<#{ tag }>#{ <%= ::HamlCoffeeAssets.config.customPreserve %>(content) }</#{ tag }>"
53
53
 
54
54
  # The surround helper surrounds the function output
metadata CHANGED
@@ -1,59 +1,215 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: haml_coffee_assets
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.16.0
4
+ version: 1.19.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michael Kessler
8
+ - Emilio Forrer
9
+ - Christopher Ostrowski
8
10
  autorequire:
9
11
  bindir: bin
10
12
  cert_chain: []
11
- date: 2013-12-03 00:00:00.000000000 Z
13
+ date: 2021-02-25 00:00:00.000000000 Z
12
14
  dependencies:
13
15
  - !ruby/object:Gem::Dependency
14
16
  name: coffee-script
15
17
  requirement: !ruby/object:Gem::Requirement
16
18
  requirements:
17
- - - "~>"
19
+ - - ">="
18
20
  - !ruby/object:Gem::Version
19
- version: '2.0'
21
+ version: '2'
20
22
  type: :runtime
21
23
  prerelease: false
22
24
  version_requirements: !ruby/object:Gem::Requirement
23
25
  requirements:
24
- - - "~>"
26
+ - - ">="
25
27
  - !ruby/object:Gem::Version
26
- version: '2.0'
28
+ version: '2'
27
29
  - !ruby/object:Gem::Dependency
28
- name: tilt
30
+ name: sprockets
29
31
  requirement: !ruby/object:Gem::Requirement
30
32
  requirements:
31
- - - "~>"
33
+ - - ">="
32
34
  - !ruby/object:Gem::Version
33
- version: '1.1'
35
+ version: '2'
34
36
  type: :runtime
35
37
  prerelease: false
36
38
  version_requirements: !ruby/object:Gem::Requirement
37
39
  requirements:
38
- - - "~>"
40
+ - - ">="
39
41
  - !ruby/object:Gem::Version
40
- version: '1.1'
42
+ version: '2'
41
43
  - !ruby/object:Gem::Dependency
42
- name: sprockets
44
+ name: bundler
43
45
  requirement: !ruby/object:Gem::Requirement
44
46
  requirements:
45
- - - "~>"
47
+ - - ">="
46
48
  - !ruby/object:Gem::Version
47
- version: '2.0'
48
- type: :runtime
49
+ version: '0'
50
+ type: :development
49
51
  prerelease: false
50
52
  version_requirements: !ruby/object:Gem::Requirement
51
53
  requirements:
52
- - - "~>"
54
+ - - ">="
53
55
  - !ruby/object:Gem::Version
54
- version: '2.0'
56
+ version: '0'
55
57
  - !ruby/object:Gem::Dependency
56
- name: bundler
58
+ name: rspec
59
+ requirement: !ruby/object:Gem::Requirement
60
+ requirements:
61
+ - - ">="
62
+ - !ruby/object:Gem::Version
63
+ version: '0'
64
+ type: :development
65
+ prerelease: false
66
+ version_requirements: !ruby/object:Gem::Requirement
67
+ requirements:
68
+ - - ">="
69
+ - !ruby/object:Gem::Version
70
+ version: '0'
71
+ - !ruby/object:Gem::Dependency
72
+ name: jquery-rails
73
+ requirement: !ruby/object:Gem::Requirement
74
+ requirements:
75
+ - - ">="
76
+ - !ruby/object:Gem::Version
77
+ version: '0'
78
+ type: :development
79
+ prerelease: false
80
+ version_requirements: !ruby/object:Gem::Requirement
81
+ requirements:
82
+ - - ">="
83
+ - !ruby/object:Gem::Version
84
+ version: '0'
85
+ - !ruby/object:Gem::Dependency
86
+ name: coffee-rails
87
+ requirement: !ruby/object:Gem::Requirement
88
+ requirements:
89
+ - - ">="
90
+ - !ruby/object:Gem::Version
91
+ version: '0'
92
+ type: :development
93
+ prerelease: false
94
+ version_requirements: !ruby/object:Gem::Requirement
95
+ requirements:
96
+ - - ">="
97
+ - !ruby/object:Gem::Version
98
+ version: '0'
99
+ - !ruby/object:Gem::Dependency
100
+ name: jasmine
101
+ requirement: !ruby/object:Gem::Requirement
102
+ requirements:
103
+ - - ">="
104
+ - !ruby/object:Gem::Version
105
+ version: '0'
106
+ type: :development
107
+ prerelease: false
108
+ version_requirements: !ruby/object:Gem::Requirement
109
+ requirements:
110
+ - - ">="
111
+ - !ruby/object:Gem::Version
112
+ version: '0'
113
+ - !ruby/object:Gem::Dependency
114
+ name: jasmine-rails
115
+ requirement: !ruby/object:Gem::Requirement
116
+ requirements:
117
+ - - ">="
118
+ - !ruby/object:Gem::Version
119
+ version: '0'
120
+ type: :development
121
+ prerelease: false
122
+ version_requirements: !ruby/object:Gem::Requirement
123
+ requirements:
124
+ - - ">="
125
+ - !ruby/object:Gem::Version
126
+ version: '0'
127
+ - !ruby/object:Gem::Dependency
128
+ name: guard
129
+ requirement: !ruby/object:Gem::Requirement
130
+ requirements:
131
+ - - ">="
132
+ - !ruby/object:Gem::Version
133
+ version: '0'
134
+ type: :development
135
+ prerelease: false
136
+ version_requirements: !ruby/object:Gem::Requirement
137
+ requirements:
138
+ - - ">="
139
+ - !ruby/object:Gem::Version
140
+ version: '0'
141
+ - !ruby/object:Gem::Dependency
142
+ name: guard-jasmine
143
+ requirement: !ruby/object:Gem::Requirement
144
+ requirements:
145
+ - - ">="
146
+ - !ruby/object:Gem::Version
147
+ version: '0'
148
+ type: :development
149
+ prerelease: false
150
+ version_requirements: !ruby/object:Gem::Requirement
151
+ requirements:
152
+ - - ">="
153
+ - !ruby/object:Gem::Version
154
+ version: '0'
155
+ - !ruby/object:Gem::Dependency
156
+ name: guard-rspec
157
+ requirement: !ruby/object:Gem::Requirement
158
+ requirements:
159
+ - - ">="
160
+ - !ruby/object:Gem::Version
161
+ version: '0'
162
+ type: :development
163
+ prerelease: false
164
+ version_requirements: !ruby/object:Gem::Requirement
165
+ requirements:
166
+ - - ">="
167
+ - !ruby/object:Gem::Version
168
+ version: '0'
169
+ - !ruby/object:Gem::Dependency
170
+ name: rake
171
+ requirement: !ruby/object:Gem::Requirement
172
+ requirements:
173
+ - - ">="
174
+ - !ruby/object:Gem::Version
175
+ version: '0'
176
+ type: :development
177
+ prerelease: false
178
+ version_requirements: !ruby/object:Gem::Requirement
179
+ requirements:
180
+ - - ">="
181
+ - !ruby/object:Gem::Version
182
+ version: '0'
183
+ - !ruby/object:Gem::Dependency
184
+ name: yard
185
+ requirement: !ruby/object:Gem::Requirement
186
+ requirements:
187
+ - - ">="
188
+ - !ruby/object:Gem::Version
189
+ version: '0'
190
+ type: :development
191
+ prerelease: false
192
+ version_requirements: !ruby/object:Gem::Requirement
193
+ requirements:
194
+ - - ">="
195
+ - !ruby/object:Gem::Version
196
+ version: '0'
197
+ - !ruby/object:Gem::Dependency
198
+ name: pry
199
+ requirement: !ruby/object:Gem::Requirement
200
+ requirements:
201
+ - - ">="
202
+ - !ruby/object:Gem::Version
203
+ version: '0'
204
+ type: :development
205
+ prerelease: false
206
+ version_requirements: !ruby/object:Gem::Requirement
207
+ requirements:
208
+ - - ">="
209
+ - !ruby/object:Gem::Version
210
+ version: '0'
211
+ - !ruby/object:Gem::Dependency
212
+ name: rb-readline
57
213
  requirement: !ruby/object:Gem::Requirement
58
214
  requirements:
59
215
  - - ">="
@@ -68,11 +224,16 @@ dependencies:
68
224
  version: '0'
69
225
  description: Compile Haml CoffeeScript templates in the Rails asset pipeline.
70
226
  email:
71
- - michi@netzpiraten.ch
227
+ - michi@flinkfinger.com
228
+ - emilio.forrer@gmail.com
229
+ - chris.ostrowski@gmail.com
72
230
  executables: []
73
231
  extensions: []
74
232
  extra_rdoc_files: []
75
233
  files:
234
+ - LICENSE
235
+ - README.md
236
+ - lib/haml_coffee_assets.rb
76
237
  - lib/haml_coffee_assets/action_view/patches.rb
77
238
  - lib/haml_coffee_assets/action_view/resolver.rb
78
239
  - lib/haml_coffee_assets/action_view/template_handler.rb
@@ -80,17 +241,13 @@ files:
80
241
  - lib/haml_coffee_assets/configuration.rb
81
242
  - lib/haml_coffee_assets/global_context.rb
82
243
  - lib/haml_coffee_assets/rails/engine.rb
83
- - lib/haml_coffee_assets/tilt/template_handler.rb
244
+ - lib/haml_coffee_assets/transformer.rb
84
245
  - lib/haml_coffee_assets/version.rb
85
- - lib/haml_coffee_assets/version.rbc
86
- - lib/haml_coffee_assets.rb
87
246
  - lib/js/haml_coffee_assets.js
88
247
  - lib/js/hamlcoffee.js
89
248
  - vendor/assets/javascripts/hamlcoffee.js.coffee.erb
90
249
  - vendor/assets/javascripts/hamlcoffee_amd.js.coffee.erb
91
- - LICENSE
92
- - README.md
93
- homepage: https://github.com/netzpirat/haml_coffee_assets
250
+ homepage: https://github.com/emilioforrer/haml_coffee_assets
94
251
  licenses:
95
252
  - MIT
96
253
  metadata: {}
@@ -102,17 +259,15 @@ required_ruby_version: !ruby/object:Gem::Requirement
102
259
  requirements:
103
260
  - - ">="
104
261
  - !ruby/object:Gem::Version
105
- version: '0'
262
+ version: 1.9.3
106
263
  required_rubygems_version: !ruby/object:Gem::Requirement
107
264
  requirements:
108
265
  - - ">="
109
266
  - !ruby/object:Gem::Version
110
267
  version: 1.3.6
111
268
  requirements: []
112
- rubyforge_project: haml_coffee_assets
113
- rubygems_version: 2.1.11
269
+ rubygems_version: 3.0.8
114
270
  signing_key:
115
271
  specification_version: 4
116
272
  summary: Haml CoffeeScript templates
117
273
  test_files: []
118
- has_rdoc:
@@ -1,48 +0,0 @@
1
- # coding: UTF-8
2
-
3
- require 'tilt'
4
-
5
- module HamlCoffeeAssets
6
- module Tilt
7
-
8
- # Haml Coffee template handler implementation for Tilt.
9
- #
10
- class TemplateHandler < ::Tilt::Template
11
-
12
- self.default_mime_type = 'application/javascript'
13
-
14
- # Test if the compiler is initialized.
15
- #
16
- # @return [Boolean] the initialization status
17
- #
18
- def self.engine_initialized?
19
- defined? HamlCoffeeAssets::Compiler
20
- end
21
-
22
- # Initialize the template engine.
23
- #
24
- def initialize_engine
25
- require_template_library 'haml_coffee_assets/compiler'
26
- end
27
-
28
- # Prepare the template
29
- #
30
- def prepare
31
- end
32
-
33
- # Compile the template.
34
- #
35
- def evaluate(scope, locals = { }, &block)
36
- jst = !!(scope.pathname.to_s =~ /\.jst\.hamlc(?:\.|$)/)
37
- name = scope.logical_path
38
- name = HamlCoffeeAssets.config.name_filter.call(name) if HamlCoffeeAssets.config.name_filter && !jst
39
-
40
- @output ||= HamlCoffeeAssets::Compiler.compile(name, data, !jst)
41
- end
42
-
43
- private
44
-
45
- end
46
-
47
- end
48
- end
@@ -1,180 +0,0 @@
1
- !RBIX
2
- 9595534255132031488
3
- x
4
- M
5
- 1
6
- n
7
- n
8
- x
9
- 10
10
- __script__
11
- i
12
- 28
13
- 99
14
- 7
15
- 0
16
- 65
17
- 49
18
- 1
19
- 2
20
- 13
21
- 99
22
- 12
23
- 7
24
- 2
25
- 12
26
- 7
27
- 3
28
- 12
29
- 65
30
- 12
31
- 49
32
- 4
33
- 4
34
- 15
35
- 49
36
- 2
37
- 0
38
- 15
39
- 2
40
- 11
41
- I
42
- 6
43
- I
44
- 0
45
- I
46
- 0
47
- I
48
- 0
49
- n
50
- p
51
- 5
52
- x
53
- 16
54
- HamlCoffeeAssets
55
- x
56
- 11
57
- open_module
58
- x
59
- 15
60
- __module_init__
61
- M
62
- 1
63
- n
64
- n
65
- x
66
- 16
67
- HamlCoffeeAssets
68
- i
69
- 48
70
- 5
71
- 66
72
- 26
73
- 93
74
- 0
75
- 15
76
- 29
77
- 21
78
- 0
79
- 45
80
- 0
81
- 1
82
- 7
83
- 2
84
- 3
85
- 98
86
- 3
87
- 3
88
- 30
89
- 8
90
- 27
91
- 25
92
- 92
93
- 0
94
- 27
95
- 8
96
- 32
97
- 15
98
- 7
99
- 4
100
- 8
101
- 33
102
- 1
103
- 9
104
- 38
105
- 1
106
- 8
107
- 47
108
- 65
109
- 7
110
- 2
111
- 7
112
- 5
113
- 64
114
- 49
115
- 6
116
- 2
117
- 11
118
- I
119
- 4
120
- I
121
- 0
122
- I
123
- 0
124
- I
125
- 0
126
- n
127
- p
128
- 7
129
- x
130
- 16
131
- HamlCoffeeAssets
132
- n
133
- x
134
- 7
135
- VERSION
136
- x
137
- 22
138
- vm_const_defined_under
139
- s
140
- 8
141
- constant
142
- s
143
- 5
144
- 0.8.2
145
- x
146
- 9
147
- const_set
148
- p
149
- 5
150
- I
151
- 2
152
- I
153
- 4
154
- I
155
- 2f
156
- I
157
- 0
158
- I
159
- 30
160
- x
161
- 78
162
- /Users/michi/Repositories/haml_coffee_assets/lib/haml_coffee_assets/version.rb
163
- p
164
- 0
165
- x
166
- 13
167
- attach_method
168
- p
169
- 3
170
- I
171
- 0
172
- I
173
- 3
174
- I
175
- 1c
176
- x
177
- 78
178
- /Users/michi/Repositories/haml_coffee_assets/lib/haml_coffee_assets/version.rb
179
- p
180
- 0