-
-
Save milligramme/3992432 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
%w(sinatra/base json pygments).each{|x| require x} | |
inp = ARGF.read | |
jsn = JSON.pretty_generate(JSON.parse inp) | |
Sinatra.new{ get("/"){ "<style>#{Pygments.css}</style>#{Pygments.highlight(jsn, :lexer => 'json')}" }}.run! |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment