liquidscript 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (72) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +18 -0
  3. data/.rspec +2 -0
  4. data/.travis.yml +8 -0
  5. data/Gemfile +11 -0
  6. data/Guardfile +9 -0
  7. data/LICENSE.txt +22 -0
  8. data/README.md +59 -0
  9. data/Rakefile +25 -0
  10. data/lib/liquidscript.rb +11 -0
  11. data/lib/liquidscript/buffer.rb +34 -0
  12. data/lib/liquidscript/compiler.rb +9 -0
  13. data/lib/liquidscript/compiler/base.rb +101 -0
  14. data/lib/liquidscript/compiler/base/action.rb +39 -0
  15. data/lib/liquidscript/compiler/base/blank.rb +24 -0
  16. data/lib/liquidscript/compiler/base/callable.rb +51 -0
  17. data/lib/liquidscript/compiler/base/helpers.rb +207 -0
  18. data/lib/liquidscript/compiler/icr.rb +40 -0
  19. data/lib/liquidscript/compiler/icr/classes.rb +59 -0
  20. data/lib/liquidscript/compiler/icr/expressions.rb +94 -0
  21. data/lib/liquidscript/compiler/icr/functions.rb +42 -0
  22. data/lib/liquidscript/compiler/icr/helpers.rb +20 -0
  23. data/lib/liquidscript/compiler/icr/literals.rb +106 -0
  24. data/lib/liquidscript/errors.rb +51 -0
  25. data/lib/liquidscript/generator.rb +11 -0
  26. data/lib/liquidscript/generator/base.rb +25 -0
  27. data/lib/liquidscript/generator/base/dsl.rb +19 -0
  28. data/lib/liquidscript/generator/base/replacements.rb +33 -0
  29. data/lib/liquidscript/generator/context.rb +7 -0
  30. data/lib/liquidscript/generator/javascript.rb +37 -0
  31. data/lib/liquidscript/generator/javascript/literals.rb +63 -0
  32. data/lib/liquidscript/generator/javascript/metas.rb +41 -0
  33. data/lib/liquidscript/generator/javascript/objects.rb +137 -0
  34. data/lib/liquidscript/icr.rb +18 -0
  35. data/lib/liquidscript/icr/code.rb +68 -0
  36. data/lib/liquidscript/icr/context.rb +94 -0
  37. data/lib/liquidscript/icr/representable.rb +39 -0
  38. data/lib/liquidscript/icr/set.rb +147 -0
  39. data/lib/liquidscript/icr/sexp.rb +41 -0
  40. data/lib/liquidscript/icr/variable.rb +68 -0
  41. data/lib/liquidscript/scanner.rb +40 -0
  42. data/lib/liquidscript/scanner/lexer.rl +106 -0
  43. data/lib/liquidscript/scanner/token.rb +37 -0
  44. data/lib/liquidscript/template.rb +16 -0
  45. data/lib/liquidscript/version.rb +5 -0
  46. data/liquidscript.gemspec +27 -0
  47. data/spec/fixtures/class.compile.yml +26 -0
  48. data/spec/fixtures/class.generate.yml +31 -0
  49. data/spec/fixtures/combination.generate.yml +33 -0
  50. data/spec/fixtures/complex.generate.yml +20 -0
  51. data/spec/fixtures/expression.generate.yml +4 -0
  52. data/spec/fixtures/function.generate.yml +11 -0
  53. data/spec/fixtures/get.generate.yml +5 -0
  54. data/spec/fixtures/literals.generate.yml +8 -0
  55. data/spec/fixtures/main.compile.yml +32 -0
  56. data/spec/fixtures/set.generate.yml +4 -0
  57. data/spec/fixtures/string.generate.yml +6 -0
  58. data/spec/lib/liquidscript/buffer_spec.rb +14 -0
  59. data/spec/lib/liquidscript/compiler/icr_spec.rb +139 -0
  60. data/spec/lib/liquidscript/generator/javascript_spec.rb +15 -0
  61. data/spec/lib/liquidscript/icr/code_spec.rb +0 -0
  62. data/spec/lib/liquidscript/icr/context_spec.rb +36 -0
  63. data/spec/lib/liquidscript/icr/set_spec.rb +59 -0
  64. data/spec/lib/liquidscript/scanner/lexer_spec.rb +58 -0
  65. data/spec/lib/liquidscript/scanner/token_spec.rb +0 -0
  66. data/spec/lib/liquidscript/scanner_spec.rb +21 -0
  67. data/spec/spec_helper.rb +30 -0
  68. data/spec/support/helpers/lexer_helper.rb +5 -0
  69. data/spec/support/matchers/be_token.rb +9 -0
  70. data/spec/support/matchers/compile.rb +41 -0
  71. data/spec/support/matchers/generate.rb +46 -0
  72. metadata +210 -0
metadata ADDED
@@ -0,0 +1,210 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: liquidscript
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.1
5
+ platform: ruby
6
+ authors:
7
+ - Jeremy Rodi
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2014-03-07 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: bundler
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '1.5'
20
+ type: :development
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '1.5'
27
+ - !ruby/object:Gem::Dependency
28
+ name: rake
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ">="
32
+ - !ruby/object:Gem::Version
33
+ version: '0'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - ">="
39
+ - !ruby/object:Gem::Version
40
+ version: '0'
41
+ - !ruby/object:Gem::Dependency
42
+ name: rspec
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - ">="
46
+ - !ruby/object:Gem::Version
47
+ version: '0'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - ">="
53
+ - !ruby/object:Gem::Version
54
+ version: '0'
55
+ - !ruby/object:Gem::Dependency
56
+ name: yard
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - ">="
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - ">="
67
+ - !ruby/object:Gem::Version
68
+ version: '0'
69
+ - !ruby/object:Gem::Dependency
70
+ name: hashie
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - "~>"
74
+ - !ruby/object:Gem::Version
75
+ version: '2.0'
76
+ type: :runtime
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - "~>"
81
+ - !ruby/object:Gem::Version
82
+ version: '2.0'
83
+ description: A javascript-based language that compiles to javascript.
84
+ email:
85
+ - redjazz96@gmail.com
86
+ executables: []
87
+ extensions: []
88
+ extra_rdoc_files: []
89
+ files:
90
+ - ".gitignore"
91
+ - ".rspec"
92
+ - ".travis.yml"
93
+ - Gemfile
94
+ - Guardfile
95
+ - LICENSE.txt
96
+ - README.md
97
+ - Rakefile
98
+ - lib/liquidscript.rb
99
+ - lib/liquidscript/buffer.rb
100
+ - lib/liquidscript/compiler.rb
101
+ - lib/liquidscript/compiler/base.rb
102
+ - lib/liquidscript/compiler/base/action.rb
103
+ - lib/liquidscript/compiler/base/blank.rb
104
+ - lib/liquidscript/compiler/base/callable.rb
105
+ - lib/liquidscript/compiler/base/helpers.rb
106
+ - lib/liquidscript/compiler/icr.rb
107
+ - lib/liquidscript/compiler/icr/classes.rb
108
+ - lib/liquidscript/compiler/icr/expressions.rb
109
+ - lib/liquidscript/compiler/icr/functions.rb
110
+ - lib/liquidscript/compiler/icr/helpers.rb
111
+ - lib/liquidscript/compiler/icr/literals.rb
112
+ - lib/liquidscript/errors.rb
113
+ - lib/liquidscript/generator.rb
114
+ - lib/liquidscript/generator/base.rb
115
+ - lib/liquidscript/generator/base/dsl.rb
116
+ - lib/liquidscript/generator/base/replacements.rb
117
+ - lib/liquidscript/generator/context.rb
118
+ - lib/liquidscript/generator/javascript.rb
119
+ - lib/liquidscript/generator/javascript/literals.rb
120
+ - lib/liquidscript/generator/javascript/metas.rb
121
+ - lib/liquidscript/generator/javascript/objects.rb
122
+ - lib/liquidscript/icr.rb
123
+ - lib/liquidscript/icr/code.rb
124
+ - lib/liquidscript/icr/context.rb
125
+ - lib/liquidscript/icr/representable.rb
126
+ - lib/liquidscript/icr/set.rb
127
+ - lib/liquidscript/icr/sexp.rb
128
+ - lib/liquidscript/icr/variable.rb
129
+ - lib/liquidscript/scanner.rb
130
+ - lib/liquidscript/scanner/lexer.rl
131
+ - lib/liquidscript/scanner/token.rb
132
+ - lib/liquidscript/template.rb
133
+ - lib/liquidscript/version.rb
134
+ - liquidscript.gemspec
135
+ - spec/fixtures/class.compile.yml
136
+ - spec/fixtures/class.generate.yml
137
+ - spec/fixtures/combination.generate.yml
138
+ - spec/fixtures/complex.generate.yml
139
+ - spec/fixtures/expression.generate.yml
140
+ - spec/fixtures/function.generate.yml
141
+ - spec/fixtures/get.generate.yml
142
+ - spec/fixtures/literals.generate.yml
143
+ - spec/fixtures/main.compile.yml
144
+ - spec/fixtures/set.generate.yml
145
+ - spec/fixtures/string.generate.yml
146
+ - spec/lib/liquidscript/buffer_spec.rb
147
+ - spec/lib/liquidscript/compiler/icr_spec.rb
148
+ - spec/lib/liquidscript/generator/javascript_spec.rb
149
+ - spec/lib/liquidscript/icr/code_spec.rb
150
+ - spec/lib/liquidscript/icr/context_spec.rb
151
+ - spec/lib/liquidscript/icr/set_spec.rb
152
+ - spec/lib/liquidscript/scanner/lexer_spec.rb
153
+ - spec/lib/liquidscript/scanner/token_spec.rb
154
+ - spec/lib/liquidscript/scanner_spec.rb
155
+ - spec/spec_helper.rb
156
+ - spec/support/helpers/lexer_helper.rb
157
+ - spec/support/matchers/be_token.rb
158
+ - spec/support/matchers/compile.rb
159
+ - spec/support/matchers/generate.rb
160
+ homepage: https://github.com/redjazz96/liquidscript
161
+ licenses:
162
+ - MIT
163
+ metadata: {}
164
+ post_install_message:
165
+ rdoc_options: []
166
+ require_paths:
167
+ - lib
168
+ required_ruby_version: !ruby/object:Gem::Requirement
169
+ requirements:
170
+ - - ">="
171
+ - !ruby/object:Gem::Version
172
+ version: '0'
173
+ required_rubygems_version: !ruby/object:Gem::Requirement
174
+ requirements:
175
+ - - ">="
176
+ - !ruby/object:Gem::Version
177
+ version: '0'
178
+ requirements: []
179
+ rubyforge_project:
180
+ rubygems_version: 2.2.2
181
+ signing_key:
182
+ specification_version: 4
183
+ summary: A javascript-based language that compiles to javascript.
184
+ test_files:
185
+ - spec/fixtures/class.compile.yml
186
+ - spec/fixtures/class.generate.yml
187
+ - spec/fixtures/combination.generate.yml
188
+ - spec/fixtures/complex.generate.yml
189
+ - spec/fixtures/expression.generate.yml
190
+ - spec/fixtures/function.generate.yml
191
+ - spec/fixtures/get.generate.yml
192
+ - spec/fixtures/literals.generate.yml
193
+ - spec/fixtures/main.compile.yml
194
+ - spec/fixtures/set.generate.yml
195
+ - spec/fixtures/string.generate.yml
196
+ - spec/lib/liquidscript/buffer_spec.rb
197
+ - spec/lib/liquidscript/compiler/icr_spec.rb
198
+ - spec/lib/liquidscript/generator/javascript_spec.rb
199
+ - spec/lib/liquidscript/icr/code_spec.rb
200
+ - spec/lib/liquidscript/icr/context_spec.rb
201
+ - spec/lib/liquidscript/icr/set_spec.rb
202
+ - spec/lib/liquidscript/scanner/lexer_spec.rb
203
+ - spec/lib/liquidscript/scanner/token_spec.rb
204
+ - spec/lib/liquidscript/scanner_spec.rb
205
+ - spec/spec_helper.rb
206
+ - spec/support/helpers/lexer_helper.rb
207
+ - spec/support/matchers/be_token.rb
208
+ - spec/support/matchers/compile.rb
209
+ - spec/support/matchers/generate.rb
210
+ has_rdoc: