Skip to content

Instantly share code, notes, and snippets.

@martinx
Created December 23, 2008 02:47
Show Gist options
  • Save martinx/39234 to your computer and use it in GitHub Desktop.
Save martinx/39234 to your computer and use it in GitHub Desktop.
require 'rubygems'
require 'coderay'
tokens = CodeRay.scan <<-'CODE', :ruby
puts %[Hello, world!]
puts "Here\'s some #@@weird #{ { :code => "for you" } }"
CODE
print tokens.div(:line_numbers => :table, :css => :class)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment