sportdb-parser 0.3.0 → 0.3.1

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
2
  SHA256:
3
- metadata.gz: 9ebb468318f2b87c33ca66afb6c46611ce5f420258e0c41b40a2cbfabcff7a49
4
- data.tar.gz: 0cf1d511f3e936d73531442d1ca6bef94d90a50ae65346b5b57347d4d294dc77
3
+ metadata.gz: 3721d30a9ec1145f59d6bc84bb9a6cf81330fdafa00314decc2c165f2c6b92c1
4
+ data.tar.gz: a50b917e0bc5db3ac21cb4ead5507233cbd91f4b6f3b52668ef74ba8c6db6140
5
5
  SHA512:
6
- metadata.gz: e992ab97d7ae18c514de14078d30eb36adc40f5044242ce9ace089fb88b104c61b29ff86a2aa8101bb7257c3ff2ce32c6150439ff855e195bee1b26032bb0d9d
7
- data.tar.gz: 25e66e45e7daf2783bc6507a3cb2c660d9153eab9530210ef51ef6e0d5d3fc531e5891897be3b0492b0ad7ea5fe3d406a0a3dd0559549b85518360d442ed4d8b
6
+ metadata.gz: 3e286842bcb5c163d841d414a15d4cbd91359324b88106603e22ebbec19b4cb8ffff3119d92a5c9e302e6aeabbc8a7ba74975efebee11ba275ce1d49f0286c1f
7
+ data.tar.gz: f237aedda025eb35bb08b31345941a3f1f073cbf8c3495c1afcf6e45de73f067e47a8a4c55981d5881079a5ca45a04af427908f379555208c98851c5d4751aa1
data/CHANGELOG.md CHANGED
@@ -1,4 +1,4 @@
1
- ### 0.3.0
1
+ ### 0.3.1
2
2
 
3
3
  ### 0.0.1 / 2024-07-12
4
4
 
data/bin/fbtok CHANGED
@@ -22,13 +22,13 @@ parser = OptionParser.new do |parser|
22
22
 
23
23
  parser.on( "--verbose", "--debug",
24
24
  "turn on verbose / debug output (default: #{opts[:debug]})" ) do |debug|
25
- opts[:debug] = debug
25
+ opts[:debug] = true
26
26
  end
27
27
 
28
28
  parser.on( "--metal",
29
29
  "turn off typed parse tree; show to the metal tokens"+
30
30
  " (default: #{opts[:metal]})" ) do |metal|
31
- opts[:metal] = metal
31
+ opts[:metal] = true
32
32
  end
33
33
  end
34
34
  parser.parse!( args )
@@ -64,6 +64,9 @@ ROUND_RE = %r{^(
64
64
  [ ] Round
65
65
  )
66
66
  |
67
+ ## Playoff Round 1
68
+ (?: Play-?off [ ] Round [ ] [1-9][0-9]* )
69
+ |
67
70
  ## starting with preliminary
68
71
  # e.g. Preliminary round
69
72
  (?: Preliminary [ ]
@@ -59,6 +59,7 @@ def read( path, parse: false )
59
59
 
60
60
  ## process nodes
61
61
  h1 = nil
62
+ h2 = nil
62
63
  orphans = 0 ## track paragraphs's with no heading
63
64
 
64
65
  attrib_found = false
@@ -69,8 +70,14 @@ def read( path, parse: false )
69
70
 
70
71
  if type == :h1
71
72
  h1 = node[1] ## get heading text
72
- puts
73
73
  puts " = Heading 1 >#{node[1]}<"
74
+ elsif type == :h2
75
+ if h1.nil?
76
+ puts "!! WARN - no heading for subheading; skipping parse"
77
+ next
78
+ end
79
+ h2 = node[1] ## get heading text
80
+ puts " == Heading 2 >#{node[1]}<"
74
81
  elsif type == :p
75
82
 
76
83
  if h1.nil?
@@ -4,7 +4,7 @@ module SportDb
4
4
  module Parser
5
5
  MAJOR = 0 ## todo: namespace inside version or something - why? why not??
6
6
  MINOR = 3
7
- PATCH = 0
7
+ PATCH = 1
8
8
  VERSION = [MAJOR,MINOR,PATCH].join('.')
9
9
 
10
10
  def self.version
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sportdb-parser
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gerald Bauer
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-09-04 00:00:00.000000000 Z
11
+ date: 2024-09-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: cocos