summaryrefslogtreecommitdiff
path: root/sample/html_list.rb
blob: fdfa5123ac979808c3547ec92dcfebb42e2ec5e7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
$: << '..'
require 'coderay'

tokens = CodeRay.scan File.read(__FILE__), :ruby
html = tokens.html(:tab_width => 2, :line_numbers => :inline, :line_number_start => -1)

puts html.page(:title => 'CodeRay HTML Encoder Example')

commment = <<_
This code must be > 10 lines
because I want to test the correct adjustment of the line numbers.
_