[Ilugc] [Tip] Easily Convert Code To HTML

  • From: thescriptdevil@xxxxxxxxx (Ashok Gautham)
  • Date: Wed Jul 14 20:41:53 2010

On Wed, Jul 14, 2010 at 12:27 AM, Tha.Suresh <jemenisuresh@xxxxxxxxx> wrote:

?Convert Code To HTML Using Vim

If you wrote some elegant code, and want to publish it as a HTML page,
you can easily do that in vim:
In command mode, type this:

? ?:TOhtml

A new buffer will be opened with the HTML source, just save it:

? ?:wq

If the original file name was ?thasucode.c?, you?ll find a new file in
the same directory named ?thasu.c.html?. Open it with your favorite
web browser.

On GNU/Emacs,

Open a file/type one containing the code

M-x htmlfontify-buffer

It even saves your theme colors.
---
Ashok `ScriptDevil` Gautham

Other related posts: