barber-emblem 0.0.4 → 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
data/Appraisals ADDED
@@ -0,0 +1,9 @@
1
+ appraise "ember-pre4" do
2
+ # Uses handlebars rc2
3
+ gem "ember-template-compiler-source", "1.0.0.pre4.4"
4
+ end
5
+
6
+ appraise "ember-rc1" do
7
+ # Uses handlebars rc3
8
+ gem "ember-template-compiler-source", "1.0.0.rc1.1"
9
+ end
data/Gemfile CHANGED
@@ -3,6 +3,4 @@ source 'https://rubygems.org'
3
3
  # Specify your gem's dependencies in handlebars-precompiler.gemspec
4
4
  gemspec
5
5
 
6
- platform :jruby do
7
- gem 'therubyrhino'
8
- end
6
+ gem 'therubyrhino', :platform => :jruby
data/Rakefile CHANGED
@@ -2,6 +2,7 @@
2
2
  require "bundler/gem_tasks"
3
3
  require "bundler/setup"
4
4
  require "rake/testtask"
5
+ require "appraisal"
5
6
 
6
7
  namespace :test do
7
8
  desc "Run all tests"
@@ -14,9 +14,12 @@ Gem::Specification.new do |gem|
14
14
  gem.require_paths = ["lib"]
15
15
  gem.version = Barber::Emblem::VERSION
16
16
 
17
- gem.add_dependency "barber", ">= 0.2.1"
17
+ gem.add_dependency "barber", ">= 0.4.0"
18
+ gem.add_dependency "emblem-source"
19
+ gem.add_dependency "ember-template-compiler-source", ">= 1.0.0.pre4.3"
18
20
 
19
21
  gem.add_development_dependency "rake"
20
22
  gem.add_development_dependency "simplecov"
21
23
  gem.add_development_dependency "mocha"
24
+ gem.add_development_dependency "appraisal"
22
25
  end
@@ -0,0 +1,8 @@
1
+ # This file was generated by Appraisal
2
+
3
+ source "https://rubygems.org"
4
+
5
+ gem "therubyrhino", :platform=>:jruby
6
+ gem "ember-template-compiler-source", "1.0.0.pre4.4"
7
+
8
+ gemspec :path=>"../"
@@ -0,0 +1,45 @@
1
+ PATH
2
+ remote: /Users/machty/code/useful/barber-emblem
3
+ specs:
4
+ barber-emblem (0.1.0)
5
+ barber (>= 0.4.0)
6
+ ember-template-compiler-source (>= 1.0.0.pre4.3)
7
+ emblem-source
8
+
9
+ GEM
10
+ remote: https://rubygems.org/
11
+ specs:
12
+ appraisal (0.5.1)
13
+ bundler
14
+ rake
15
+ barber (0.4.0)
16
+ ember-template-compiler-source
17
+ execjs
18
+ handlebars-source
19
+ ember-template-compiler-source (1.0.0.pre4.4)
20
+ handlebars-source (>= 1.0.0.rc2)
21
+ emblem-source (0.1.8)
22
+ execjs (1.4.0)
23
+ multi_json (~> 1.0)
24
+ handlebars-source (1.0.9)
25
+ metaclass (0.0.1)
26
+ mocha (0.13.2)
27
+ metaclass (~> 0.0.1)
28
+ multi_json (1.6.1)
29
+ rake (10.0.3)
30
+ simplecov (0.7.1)
31
+ multi_json (~> 1.0)
32
+ simplecov-html (~> 0.7.1)
33
+ simplecov-html (0.7.1)
34
+
35
+ PLATFORMS
36
+ ruby
37
+
38
+ DEPENDENCIES
39
+ appraisal
40
+ barber-emblem!
41
+ ember-template-compiler-source (= 1.0.0.pre4.4)
42
+ mocha
43
+ rake
44
+ simplecov
45
+ therubyrhino
@@ -0,0 +1,8 @@
1
+ # This file was generated by Appraisal
2
+
3
+ source "https://rubygems.org"
4
+
5
+ gem "therubyrhino", :platform=>:jruby
6
+ gem "ember-template-compiler-source", "1.0.0.rc1.1"
7
+
8
+ gemspec :path=>"../"
@@ -0,0 +1,45 @@
1
+ PATH
2
+ remote: /Users/machty/code/useful/barber-emblem
3
+ specs:
4
+ barber-emblem (0.1.0)
5
+ barber (>= 0.4.0)
6
+ ember-template-compiler-source (>= 1.0.0.pre4.3)
7
+ emblem-source
8
+
9
+ GEM
10
+ remote: https://rubygems.org/
11
+ specs:
12
+ appraisal (0.5.1)
13
+ bundler
14
+ rake
15
+ barber (0.4.0)
16
+ ember-template-compiler-source
17
+ execjs
18
+ handlebars-source
19
+ ember-template-compiler-source (1.0.0.rc1.1)
20
+ handlebars-source (= 1.0.0.rc3)
21
+ emblem-source (0.1.8)
22
+ execjs (1.4.0)
23
+ multi_json (~> 1.0)
24
+ handlebars-source (1.0.0.rc.3)
25
+ metaclass (0.0.1)
26
+ mocha (0.13.2)
27
+ metaclass (~> 0.0.1)
28
+ multi_json (1.6.1)
29
+ rake (10.0.3)
30
+ simplecov (0.7.1)
31
+ multi_json (~> 1.0)
32
+ simplecov-html (~> 0.7.1)
33
+ simplecov-html (0.7.1)
34
+
35
+ PLATFORMS
36
+ ruby
37
+
38
+ DEPENDENCIES
39
+ appraisal
40
+ barber-emblem!
41
+ ember-template-compiler-source (= 1.0.0.rc1.1)
42
+ mocha
43
+ rake
44
+ simplecov
45
+ therubyrhino
@@ -1,20 +1,10 @@
1
1
  module Barber
2
2
  module Emblem
3
3
  class EmberPrecompiler < Barber::Ember::Precompiler
4
- def sources
5
- [precompiler, handlebars, emblem]
6
- end
7
-
8
- def emblem
9
- @emblem = File.new(File.expand_path("../../javascripts/emblem.js", __FILE__))
10
- end
4
+ include Shared
11
5
 
12
- def handlebars
13
- @handlebars = File.new(File.expand_path("../../javascripts/ember-template-compiler.js", __FILE__))
14
- end
15
-
16
- def precompiler
17
- @emblem = File.new(File.expand_path("../../javascripts/emblem_precompiler.js", __FILE__))
6
+ def sources
7
+ [precompiler, handlebars, ember_template_precompiler, emblem]
18
8
  end
19
9
  end
20
10
  end
@@ -1,21 +1,11 @@
1
1
  module Barber
2
2
  module Emblem
3
3
  class Precompiler < Barber::Precompiler
4
+ include Shared
5
+
4
6
  def sources
5
7
  [precompiler, handlebars, emblem]
6
8
  end
7
-
8
- def emblem
9
- @emblem = File.new(File.expand_path("../../javascripts/emblem.js", __FILE__))
10
- end
11
-
12
- def handlebars
13
- @handlebars = File.new(File.expand_path("../../javascripts/handlebars.js", __FILE__))
14
- end
15
-
16
- def precompiler
17
- @emblem = File.new(File.expand_path("../../javascripts/emblem_precompiler.js", __FILE__))
18
- end
19
9
  end
20
10
  end
21
11
  end
@@ -0,0 +1,15 @@
1
+ require 'emblem/source'
2
+
3
+ module Barber
4
+ module Emblem
5
+ module Shared
6
+ def emblem
7
+ @emblem = File.new(::Emblem::Source.bundled_path)
8
+ end
9
+
10
+ def precompiler
11
+ @emblem = File.new(File.expand_path("../../javascripts/emblem_precompiler.js", __FILE__))
12
+ end
13
+ end
14
+ end
15
+ end
@@ -1,5 +1,5 @@
1
1
  module Barber
2
2
  module Emblem
3
- VERSION = "0.0.4"
3
+ VERSION = "0.1.0"
4
4
  end
5
5
  end
File without changes
@@ -3,10 +3,15 @@ var exports = this.exports || {};
3
3
  var Emblem;
4
4
  var self = this;
5
5
 
6
+ function require() {
7
+ // ember-template-compiler only requires('handlebars')
8
+ return Handlebars;
9
+ }
10
+
6
11
  var Barber = {
7
12
  precompile: function(string) {
8
13
  Emblem = self.Emblem;
9
- var handlebarsVariant = exports.emberHandlebars || Handlebars;
14
+ var handlebarsVariant = exports.EmberHandlebars || Handlebars;
10
15
 
11
16
  return Emblem.precompile(handlebarsVariant, string).toString();
12
17
  }
data/lib/barber-emblem.rb CHANGED
@@ -1,5 +1,7 @@
1
1
  require "barber"
2
+ require "barber/emblem"
2
3
  require "barber/emblem/version"
4
+ require "barber/emblem/shared"
3
5
  require "barber/emblem/precompiler"
4
6
  require "barber/emblem/precompilers"
5
7
  require "barber/emblem/ember_precompiler"
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: barber-emblem
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.4
4
+ version: 0.1.0
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-02-17 00:00:00.000000000 Z
12
+ date: 2013-02-21 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: barber
@@ -18,7 +18,7 @@ dependencies:
18
18
  requirements:
19
19
  - - ! '>='
20
20
  - !ruby/object:Gem::Version
21
- version: 0.2.1
21
+ version: 0.4.0
22
22
  type: :runtime
23
23
  prerelease: false
24
24
  version_requirements: !ruby/object:Gem::Requirement
@@ -26,7 +26,39 @@ dependencies:
26
26
  requirements:
27
27
  - - ! '>='
28
28
  - !ruby/object:Gem::Version
29
- version: 0.2.1
29
+ version: 0.4.0
30
+ - !ruby/object:Gem::Dependency
31
+ name: emblem-source
32
+ requirement: !ruby/object:Gem::Requirement
33
+ none: false
34
+ requirements:
35
+ - - ! '>='
36
+ - !ruby/object:Gem::Version
37
+ version: '0'
38
+ type: :runtime
39
+ prerelease: false
40
+ version_requirements: !ruby/object:Gem::Requirement
41
+ none: false
42
+ requirements:
43
+ - - ! '>='
44
+ - !ruby/object:Gem::Version
45
+ version: '0'
46
+ - !ruby/object:Gem::Dependency
47
+ name: ember-template-compiler-source
48
+ requirement: !ruby/object:Gem::Requirement
49
+ none: false
50
+ requirements:
51
+ - - ! '>='
52
+ - !ruby/object:Gem::Version
53
+ version: 1.0.0.pre4.3
54
+ type: :runtime
55
+ prerelease: false
56
+ version_requirements: !ruby/object:Gem::Requirement
57
+ none: false
58
+ requirements:
59
+ - - ! '>='
60
+ - !ruby/object:Gem::Version
61
+ version: 1.0.0.pre4.3
30
62
  - !ruby/object:Gem::Dependency
31
63
  name: rake
32
64
  requirement: !ruby/object:Gem::Requirement
@@ -75,6 +107,22 @@ dependencies:
75
107
  - - ! '>='
76
108
  - !ruby/object:Gem::Version
77
109
  version: '0'
110
+ - !ruby/object:Gem::Dependency
111
+ name: appraisal
112
+ requirement: !ruby/object:Gem::Requirement
113
+ none: false
114
+ requirements:
115
+ - - ! '>='
116
+ - !ruby/object:Gem::Version
117
+ version: '0'
118
+ type: :development
119
+ prerelease: false
120
+ version_requirements: !ruby/object:Gem::Requirement
121
+ none: false
122
+ requirements:
123
+ - - ! '>='
124
+ - !ruby/object:Gem::Version
125
+ version: '0'
78
126
  description: Emblem.js precompilation
79
127
  email:
80
128
  - machty@gmail.com
@@ -84,21 +132,25 @@ extra_rdoc_files: []
84
132
  files:
85
133
  - .gitignore
86
134
  - .travis.yml
135
+ - Appraisals
87
136
  - Gemfile
88
137
  - LICENSE
89
138
  - README.md
90
139
  - Rakefile
91
140
  - barber-emblem.gemspec
141
+ - gemfiles/ember_pre4.gemfile
142
+ - gemfiles/ember_pre4.gemfile.lock
143
+ - gemfiles/ember_rc1.gemfile
144
+ - gemfiles/ember_rc1.gemfile.lock
92
145
  - lib/barber-emblem.rb
146
+ - lib/barber/emblem.rb
93
147
  - lib/barber/emblem/ember_precompiler.rb
94
148
  - lib/barber/emblem/ember_precompilers.rb
95
149
  - lib/barber/emblem/precompiler.rb
96
150
  - lib/barber/emblem/precompilers.rb
151
+ - lib/barber/emblem/shared.rb
97
152
  - lib/barber/emblem/version.rb
98
- - lib/barber/javascripts/ember-template-compiler.js
99
- - lib/barber/javascripts/emblem.js
100
153
  - lib/barber/javascripts/emblem_precompiler.js
101
- - lib/barber/javascripts/handlebars.js
102
154
  - test/emblem/ember_precompiler_test.rb
103
155
  - test/emblem/ember_precompilers_test.rb
104
156
  - test/emblem/precompiler_test.rb