hanna-bootstrap 0.0.2 → 0.0.3

Sign up to get free protection for your applications and to get access to all the features.
@@ -376,9 +376,10 @@ class RDoc::Generator::Bootstrap
376
376
  indent = src.length
377
377
  lines = src.lines.to_a
378
378
  start = 0
379
+ line_numbers = @options.line_numbers
379
380
  if src =~ /\A.*#\ *File/i # remove '# File' comment
380
381
  line = lines.shift
381
- line.sub!(/\A(.*)(, line (\d+))/, '\1')
382
+ line_numbers = false unless line.sub!(/\A(.*)(, line (\d+))/, '\1')
382
383
  start = $3.to_i
383
384
  end
384
385
  lines.each do |line|
@@ -392,7 +393,7 @@ class RDoc::Generator::Bootstrap
392
393
  src.gsub!(/^#{' ' * indent}/, '') if indent > 0
393
394
 
394
395
  CodeRay.highlight(src, lang,
395
- :line_numbers => @options.line_numbers ? :table : nil,
396
+ :line_numbers => line_numbers ? :table : nil,
396
397
  :line_number_anchors => "#{method.aref}-source-",
397
398
  :line_number_start => start
398
399
  )
@@ -1,7 +1,7 @@
1
1
  module RDoc
2
2
  module Generator
3
3
  class Bootstrap
4
- VERSION = '0.0.2'
4
+ VERSION = '0.0.3'
5
5
  end
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: hanna-bootstrap
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.2
4
+ version: 0.0.3
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: