Google AdSense

Tuesday, January 13, 2015

Translate code to highlight html

Descriptions

  • Cut the code that you want to translate to the ciipboard then execute the program, the content of the clipboard will be the translated html.
  • Execute the code below to get the CSS and copy it to Blogger > Template > Customize > Adnanced > Add CSS to get colors.
  • from pygments.cmdline import main
    argv = ['pygmentize']
    argv += ['-f', 'html']
    argv += ['-S', 'native']
    main(argv)
    

Downloads

Requirements

No comments:

Post a Comment