gherkin 0.0.3-universal-java-1.5 → 0.0.4-universal-java-1.5

Sign up to get free protection for your applications and to get access to all the features.
metadata CHANGED
@@ -1,187 +1,158 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gherkin
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.0.4
5
5
  platform: universal-java-1.5
6
6
  authors:
7
- - Mike Sassak
8
- - Gregory Hnatiuk
9
- - "Aslak Helles\xC3\xB8y"
7
+ - Mike Sassak
8
+ - Gregory Hnatiuk
9
+ - "Aslak Helles\xC3\xB8y"
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
13
 
14
- date: 2009-11-25 00:00:00 +01:00
14
+ date: 2009-11-28 00:00:00 +01:00
15
15
  default_executable: gherkin
16
16
  dependencies:
17
- - !ruby/object:Gem::Dependency
18
- name: rspec
19
- type: :development
20
- version_requirement:
21
- version_requirements: !ruby/object:Gem::Requirement
22
- requirements:
23
- - - "="
24
- - !ruby/object:Gem::Version
25
- version: 1.2.9
26
- version:
27
- - !ruby/object:Gem::Dependency
28
- name: cucumber
29
- type: :development
30
- version_requirement:
31
- version_requirements: !ruby/object:Gem::Requirement
32
- requirements:
33
- - - ">="
34
- - !ruby/object:Gem::Version
35
- version: "0"
36
- version:
17
+ - !ruby/object:Gem::Dependency
18
+ name: rspec
19
+ type: :development
20
+ version_requirement:
21
+ version_requirements: !ruby/object:Gem::Requirement
22
+ requirements:
23
+ - - "="
24
+ - !ruby/object:Gem::Version
25
+ version: 1.2.9
26
+ version:
27
+ - !ruby/object:Gem::Dependency
28
+ name: cucumber
29
+ type: :development
30
+ version_requirement:
31
+ version_requirements: !ruby/object:Gem::Requirement
32
+ requirements:
33
+ - - "="
34
+ - !ruby/object:Gem::Version
35
+ version: 0.4.4
36
+ version:
37
+ - !ruby/object:Gem::Dependency
38
+ name: rake-compiler
39
+ type: :development
40
+ version_requirement:
41
+ version_requirements: !ruby/object:Gem::Requirement
42
+ requirements:
43
+ - - "="
44
+ - !ruby/object:Gem::Version
45
+ version: 0.6.0
46
+ version:
37
47
  description: A fast Gherkin lexer in Ragel
38
48
  email: cukes@googlegroups.com
39
49
  executables:
40
- - gherkin
50
+ - gherkin
41
51
  extensions: []
42
52
 
43
53
  extra_rdoc_files:
44
- - LICENSE
45
- - README.rdoc
54
+ - LICENSE
55
+ - README.rdoc
46
56
  files:
47
- - .gitignore
48
- - LICENSE
49
- - README.rdoc
50
- - Rakefile
51
- - VERSION.yml
52
- - bin/gherkin
53
- - cucumber.yml
54
- - ext/gherkin_lexer/.gitignore
55
- - ext/gherkin_lexer/extconf.rb
56
- - features/feature_parser.feature
57
- - features/native_lexer.feature
58
- - features/parser_with_native_lexer.feature
59
- - features/pretty_printer.feature
60
- - features/step_definitions/gherkin_steps.rb
61
- - features/step_definitions/pretty_printer_steps.rb
62
- - features/steps_parser.feature
63
- - features/support/env.rb
64
- - gherkin.gemspec
65
- - java/.gitignore
66
- - java/Gherkin.iml
67
- - java/build.xml
68
- - java/src/gherkin/FixJava.java
69
- - java/src/gherkin/Lexer.java
70
- - java/src/gherkin/LexingError.java
71
- - java/src/gherkin/Listener.java
72
- - java/src/gherkin/ParseError.java
73
- - java/src/gherkin/Parser.java
74
- - java/src/gherkin/lexer/.gitignore
75
- - java/src/gherkin/parser/StateMachineReader.java
76
- - lib/.gitignore
77
- - lib/gherkin.jar
78
- - lib/gherkin.rb
79
- - lib/gherkin/c_lexer.rb
80
- - lib/gherkin/i18n.yml
81
- - lib/gherkin/i18n_lexer.rb
82
- - lib/gherkin/java_lexer.rb
83
- - lib/gherkin/lexer.rb
84
- - lib/gherkin/parser.rb
85
- - lib/gherkin/parser/meta.txt
86
- - lib/gherkin/parser/root.txt
87
- - lib/gherkin/parser/steps.txt
88
- - lib/gherkin/rb_lexer.rb
89
- - lib/gherkin/rb_lexer/.gitignore
90
- - lib/gherkin/rb_lexer/README.rdoc
91
- - lib/gherkin/rb_lexer/ar.rb
92
- - lib/gherkin/rb_lexer/bg.rb
93
- - lib/gherkin/rb_lexer/cat.rb
94
- - lib/gherkin/rb_lexer/cs.rb
95
- - lib/gherkin/rb_lexer/cy.rb
96
- - lib/gherkin/rb_lexer/da.rb
97
- - lib/gherkin/rb_lexer/de.rb
98
- - lib/gherkin/rb_lexer/en-au.rb
99
- - lib/gherkin/rb_lexer/en-lol.rb
100
- - lib/gherkin/rb_lexer/en-tx.rb
101
- - lib/gherkin/rb_lexer/en.rb
102
- - lib/gherkin/rb_lexer/es.rb
103
- - lib/gherkin/rb_lexer/et.rb
104
- - lib/gherkin/rb_lexer/fi.rb
105
- - lib/gherkin/rb_lexer/fr.rb
106
- - lib/gherkin/rb_lexer/he.rb
107
- - lib/gherkin/rb_lexer/hr.rb
108
- - lib/gherkin/rb_lexer/hu.rb
109
- - lib/gherkin/rb_lexer/id.rb
110
- - lib/gherkin/rb_lexer/it.rb
111
- - lib/gherkin/rb_lexer/ja.rb
112
- - lib/gherkin/rb_lexer/ko.rb
113
- - lib/gherkin/rb_lexer/lt.rb
114
- - lib/gherkin/rb_lexer/lv.rb
115
- - lib/gherkin/rb_lexer/nl.rb
116
- - lib/gherkin/rb_lexer/no.rb
117
- - lib/gherkin/rb_lexer/pl.rb
118
- - lib/gherkin/rb_lexer/pt.rb
119
- - lib/gherkin/rb_lexer/ro.rb
120
- - lib/gherkin/rb_lexer/ro2.rb
121
- - lib/gherkin/rb_lexer/ru.rb
122
- - lib/gherkin/rb_lexer/se.rb
123
- - lib/gherkin/rb_lexer/sk.rb
124
- - lib/gherkin/rb_lexer/sr-Latn.rb
125
- - lib/gherkin/rb_lexer/sr.rb
126
- - lib/gherkin/rb_lexer/tr.rb
127
- - lib/gherkin/rb_lexer/uz.rb
128
- - lib/gherkin/rb_lexer/vi.rb
129
- - lib/gherkin/rb_lexer/zh-CN.rb
130
- - lib/gherkin/rb_lexer/zh-TW.rb
131
- - lib/gherkin/rb_parser.rb
132
- - lib/gherkin/tools/pretty_printer.rb
133
- - ragel/i18n/.gitignore
134
- - ragel/lexer.c.rl.erb
135
- - ragel/lexer.java.rl.erb
136
- - ragel/lexer.rb.rl.erb
137
- - ragel/lexer_common.rl.erb
138
- - spec/gherkin/c_lexer_spec.rb
139
- - spec/gherkin/fixtures/complex.feature
140
- - spec/gherkin/fixtures/i18n_fr.feature
141
- - spec/gherkin/fixtures/i18n_no.feature
142
- - spec/gherkin/fixtures/i18n_zh-CN.feature
143
- - spec/gherkin/fixtures/simple.feature
144
- - spec/gherkin/fixtures/simple_with_comments.feature
145
- - spec/gherkin/fixtures/simple_with_tags.feature
146
- - spec/gherkin/i18n_spec.rb
147
- - spec/gherkin/java_lexer_spec.rb
148
- - spec/gherkin/parser_spec.rb
149
- - spec/gherkin/rb_lexer_spec.rb
150
- - spec/gherkin/sexp_recorder.rb
151
- - spec/gherkin/shared/lexer_spec.rb
152
- - spec/gherkin/shared/py_string_spec.rb
153
- - spec/gherkin/shared/table_spec.rb
154
- - spec/gherkin/shared/tags_spec.rb
155
- - spec/spec_helper.rb
156
- - tasks/bench.rake
157
- - tasks/bench/feature_builder.rb
158
- - tasks/bench/generated/.gitignore
159
- - tasks/bench/null_listener.rb
160
- - tasks/cucumber.rake
161
- - tasks/ext.rake
162
- - tasks/ragel.rake
163
- - tasks/rdoc.rake
164
- - tasks/rspec.rake
57
+ - .gitignore
58
+ - LICENSE
59
+ - README.rdoc
60
+ - Rakefile
61
+ - VERSION.yml
62
+ - bin/gherkin
63
+ - cucumber.yml
64
+ - features/feature_parser.feature
65
+ - features/native_lexer.feature
66
+ - features/parser_with_native_lexer.feature
67
+ - features/pretty_printer.feature
68
+ - features/step_definitions/gherkin_steps.rb
69
+ - features/step_definitions/pretty_printer_steps.rb
70
+ - features/steps_parser.feature
71
+ - features/support/env.rb
72
+ - gherkin.gemspec
73
+ - java/.gitignore
74
+ - java/Gherkin.iml
75
+ - java/build.xml
76
+ - java/src/gherkin/FixJava.java
77
+ - java/src/gherkin/Lexer.java
78
+ - java/src/gherkin/LexingError.java
79
+ - java/src/gherkin/Listener.java
80
+ - java/src/gherkin/ParseError.java
81
+ - java/src/gherkin/Parser.java
82
+ - java/src/gherkin/lexer/.gitignore
83
+ - java/src/gherkin/parser/StateMachineReader.java
84
+ - lib/.gitignore
85
+ - lib/gherkin.jar
86
+ - lib/gherkin.rb
87
+ - lib/gherkin/c_lexer.rb
88
+ - lib/gherkin/core_ext/array.rb
89
+ - lib/gherkin/i18n.yml
90
+ - lib/gherkin/i18n_lexer.rb
91
+ - lib/gherkin/java_lexer.rb
92
+ - lib/gherkin/lexer.rb
93
+ - lib/gherkin/parser.rb
94
+ - lib/gherkin/parser/meta.txt
95
+ - lib/gherkin/parser/root.txt
96
+ - lib/gherkin/parser/steps.txt
97
+ - lib/gherkin/rb_lexer.rb
98
+ - lib/gherkin/rb_lexer/.gitignore
99
+ - lib/gherkin/rb_lexer/README.rdoc
100
+ - lib/gherkin/rb_parser.rb
101
+ - lib/gherkin/tools/pretty_printer.rb
102
+ - nativegems.sh
103
+ - ragel/i18n/.gitignore
104
+ - ragel/lexer.c.rl.erb
105
+ - ragel/lexer.java.rl.erb
106
+ - ragel/lexer.rb.rl.erb
107
+ - ragel/lexer_common.rl.erb
108
+ - spec/gherkin/c_lexer_spec.rb
109
+ - spec/gherkin/fixtures/1.feature
110
+ - spec/gherkin/fixtures/complex.feature
111
+ - spec/gherkin/fixtures/i18n_fr.feature
112
+ - spec/gherkin/fixtures/i18n_no.feature
113
+ - spec/gherkin/fixtures/i18n_zh-CN.feature
114
+ - spec/gherkin/fixtures/simple.feature
115
+ - spec/gherkin/fixtures/simple_with_comments.feature
116
+ - spec/gherkin/fixtures/simple_with_tags.feature
117
+ - spec/gherkin/i18n_spec.rb
118
+ - spec/gherkin/java_lexer_spec.rb
119
+ - spec/gherkin/parser_spec.rb
120
+ - spec/gherkin/rb_lexer_spec.rb
121
+ - spec/gherkin/sexp_recorder.rb
122
+ - spec/gherkin/shared/lexer_spec.rb
123
+ - spec/gherkin/shared/py_string_spec.rb
124
+ - spec/gherkin/shared/table_spec.rb
125
+ - spec/gherkin/shared/tags_spec.rb
126
+ - spec/spec_helper.rb
127
+ - tasks/bench.rake
128
+ - tasks/bench/feature_builder.rb
129
+ - tasks/bench/generated/.gitignore
130
+ - tasks/bench/null_listener.rb
131
+ - tasks/compile.rake
132
+ - tasks/cucumber.rake
133
+ - tasks/ragel_task.rb
134
+ - tasks/rdoc.rake
135
+ - tasks/rspec.rake
165
136
  has_rdoc: true
166
137
  homepage: http://github.com/aslakhellesoy/gherkin
167
138
  licenses: []
168
139
 
169
140
  post_install_message:
170
141
  rdoc_options:
171
- - --charset=UTF-8
142
+ - --charset=UTF-8
172
143
  require_paths:
173
- - lib
144
+ - lib
174
145
  required_ruby_version: !ruby/object:Gem::Requirement
175
146
  requirements:
176
- - - ">="
177
- - !ruby/object:Gem::Version
178
- version: "0"
147
+ - - ">="
148
+ - !ruby/object:Gem::Version
149
+ version: "0"
179
150
  version:
180
151
  required_rubygems_version: !ruby/object:Gem::Requirement
181
152
  requirements:
182
- - - ">="
183
- - !ruby/object:Gem::Version
184
- version: "0"
153
+ - - ">="
154
+ - !ruby/object:Gem::Version
155
+ version: "0"
185
156
  version:
186
157
  requirements: []
187
158
 
@@ -191,14 +162,14 @@ signing_key:
191
162
  specification_version: 3
192
163
  summary: Fast Gherkin lexer
193
164
  test_files:
194
- - spec/spec_helper.rb
195
- - spec/gherkin/c_lexer_spec.rb
196
- - spec/gherkin/i18n_spec.rb
197
- - spec/gherkin/java_lexer_spec.rb
198
- - spec/gherkin/parser_spec.rb
199
- - spec/gherkin/rb_lexer_spec.rb
200
- - spec/gherkin/sexp_recorder.rb
201
- - spec/gherkin/shared/lexer_spec.rb
202
- - spec/gherkin/shared/py_string_spec.rb
203
- - spec/gherkin/shared/table_spec.rb
204
- - spec/gherkin/shared/tags_spec.rb
165
+ - spec/gherkin/c_lexer_spec.rb
166
+ - spec/gherkin/i18n_spec.rb
167
+ - spec/gherkin/java_lexer_spec.rb
168
+ - spec/gherkin/parser_spec.rb
169
+ - spec/gherkin/rb_lexer_spec.rb
170
+ - spec/gherkin/sexp_recorder.rb
171
+ - spec/gherkin/shared/lexer_spec.rb
172
+ - spec/gherkin/shared/py_string_spec.rb
173
+ - spec/gherkin/shared/table_spec.rb
174
+ - spec/gherkin/shared/tags_spec.rb
175
+ - spec/spec_helper.rb
@@ -1,6 +0,0 @@
1
- Makefile
2
- *.bundle
3
- *.log
4
- en.c
5
- *.o
6
- *dSYM/
@@ -1,6 +0,0 @@
1
- require 'mkmf'
2
-
3
- dir_config("gherkin_lexer")
4
- have_library("c", "main")
5
-
6
- create_makefile("gherkin_lexer")
@@ -1,49 +0,0 @@
1
- CLEAN.include [
2
- '**/*.{o,bundle,jar,so,obj,pdb,lib,def,exp,log}', 'ext/*/Makefile', 'ext/*/conftest.dSYM',
3
- 'java/target'
4
- ]
5
-
6
- if(defined?(JRUBY_VERSION))
7
-
8
- def ext_task(name)
9
- desc "Compile the Native Java extensions"
10
- task :compile => ['ragel:java'] do
11
- sh("ant -f java/build.xml")
12
- end
13
- end
14
-
15
- else # NOT JRUBY
16
-
17
- def ext_task(name)
18
- ext_dir = "ext/#{name}"
19
- ext_bundle = "#{ext_dir}/#{name}.#{Config::CONFIG['DLEXT']}"
20
- ext_files = FileList[
21
- "#{ext_dir}/*.c",
22
- "#{ext_dir}/*.h",
23
- "#{ext_dir}/*.rl",
24
- "#{ext_dir}/extconf.rb",
25
- "#{ext_dir}/Makefile",
26
- "lib"
27
- ]
28
-
29
- task "compile:#{name}" => ["#{ext_dir}/Makefile", ext_bundle]
30
-
31
- desc "Compile the Native C extensions"
32
- task :compile => ['ragel:c', "compile:#{name}"]
33
-
34
- file "#{ext_dir}/Makefile" => ["#{ext_dir}/extconf.rb"] do
35
- cd(ext_dir) { ruby "extconf.rb" }
36
- end
37
-
38
- file ext_bundle => ext_files do
39
- cd ext_dir do
40
- sh(WINDOWS ? 'nmake' : 'make')
41
- end
42
- cp ext_bundle, 'lib/'
43
- end
44
- end
45
- end
46
-
47
- ext_task :gherkin_lexer
48
-
49
- task :package => :compile
@@ -1,94 +0,0 @@
1
- CLEAN.include [
2
- 'ragel/i18n/*.rl',
3
- 'lib/gherkin/rb_lexer/*.rb',
4
- 'ext/gherkin_lexer/*.c',
5
- 'java/src/gherkin/lexer/*.java',
6
- ]
7
-
8
- class RagelCompiler
9
- RL_OUTPUT_DIR = File.dirname(__FILE__) + "/../ragel/i18n"
10
-
11
- def initialize(target)
12
- require 'yaml'
13
- require 'erb'
14
-
15
- @target = target
16
- @flag, @output_dir, @filename_proc = case
17
- when @target == "rb" then ["-R", "lib/gherkin/rb_lexer", lambda{|name| name}]
18
- when @target == "c" then ["-C", "ext/gherkin_lexer", lambda{|name| name}]
19
- when @target == "java" then ["-J", "java/src/gherkin/lexer", lambda{|name| name.gsub(/[\s-]/, '').capitalize}]
20
- end
21
-
22
- @i18n_languages = YAML.load_file(File.dirname(__FILE__) + '/../lib/gherkin/i18n.yml')
23
- @common_tmpl = ERB.new(IO.read(File.dirname(__FILE__) + '/../ragel/lexer_common.rl.erb'))
24
- @actions_tmpl = ERB.new(IO.read(File.dirname(__FILE__) + "/../ragel/lexer.#{@target}.rl.erb"))
25
- end
26
-
27
- def compile_all
28
- @i18n_languages.keys.each do |lang|
29
- compile(lang)
30
- end
31
- end
32
-
33
- def compile(i18n_language)
34
- FileUtils.mkdir(RL_OUTPUT_DIR) unless File.exist?(RL_OUTPUT_DIR)
35
-
36
- common_path = RL_OUTPUT_DIR + "/lexer_common.#{i18n_language}.rl"
37
- actions_path = RL_OUTPUT_DIR + "/#{i18n_language}.#{@target}.rl"
38
-
39
- generate_common(i18n_language, common_path)
40
- generate_actions(i18n_language, actions_path)
41
-
42
- sh "ragel #{@flag} #{actions_path} -o #{@output_dir}/#{@filename_proc.call(i18n_language)}.#{@target}"
43
- end
44
-
45
- def generate_common(i18n_language, path)
46
- i18n = prep_keywords(@i18n_languages['en'].merge(@i18n_languages[i18n_language]))
47
- common = @common_tmpl.result(binding)
48
- write common, path
49
- end
50
-
51
- def generate_actions(i18n_language, path)
52
- i18n_lexer_class_name = i18n_language.gsub(/[\s-]/, '').capitalize
53
- impl = @actions_tmpl.result(binding)
54
- write impl, path
55
- end
56
-
57
- def prep_keywords(i18n)
58
- delimited_keywords = %w{feature background scenario scenario_outline examples}
59
- bare_keywords = %w{given when then and but}
60
- all_keywords = delimited_keywords + bare_keywords
61
-
62
- all_keywords.each { |kw| i18n[kw] = i18n[kw].split("|") }
63
- delimited_keywords.each { |kw| i18n[kw].map! { |v| v += ':'} }
64
- bare_keywords.each { |kw| i18n[kw].map! { |v| (v + ' ').sub(/< $/,'')} }
65
- all_keywords.each { |kw| i18n[kw] = '("' + i18n[kw].join('" | "') + '")' }
66
- i18n
67
- end
68
-
69
- def write(content, filename)
70
- File.open(filename, "wb") do |file|
71
- file.write(content)
72
- end
73
- end
74
- end
75
-
76
- namespace :ragel do
77
- desc "Generate i18n sources for C lexers (TODO: Do it for all)"
78
- task :c do
79
- RagelCompiler.new("c").compile('en')
80
- end
81
-
82
- desc "Generate all i18n Ruby lexers"
83
- task :rb do
84
- RagelCompiler.new("rb").compile_all
85
- end
86
-
87
- desc "Generate all i18n Java lexers"
88
- task :java do
89
- RagelCompiler.new("java").compile_all
90
- end
91
- end
92
-
93
- desc "Generate all i18n lexers for all programming languages"
94
- task :ragel => ['ragel:c', 'ragel:rb', 'ragel:java']