Does anyone know of a good program that can take a text file and syntax highlight it, then export the syntax highlighted file in HTML?
SciTE (from www.scintilla.org) is an opensource text editor with syntax highlighting.
SciTe will also save as HTML. It's pretty bloated HTML but it works well.
SWEET! That is *exactly* what I need - thanks!
My favourite editor...
If the source's license is GPL, after you buy the source, you have almost the exact same rights as the authors, so you can start giving away the software yourself.
You might also want to take a look at Code2HTML ( http://www.palfrader.org/code2html/examples.html ), a perl script that exports syntax highlighted HTML for a whole range of languages.
It certainly isn't "open source" according to the OSI's "Open Source Definition", which you can find at http://www.opensource.org/docs/definition_plain.php . Unfortunately (maybe), the term "open source" isn't a trademark or anything, and no one can stop a company saying "This product is open-source: you can get the source code by paying us $1M, and then you aren't allowed to show it to anyone else" even though that's utterly incompatible with what the people who cooked the term up *want* it to mean.
You most definitely CAN withhold the source from non-paying persons if you want, even under the GPL. What you can't do is prevent them from giving it away after they have it.
Brad Wilson (dotnetguy.techieswithcats.com)
jedit ( http://www.jedit.org ) has a plugin that takes any open document and exports it to colourised html. I use that for all my code snippets in documentation etc.
i like i
A utility that will do this from the command line is enscript.
and yet another...TextPad also supports this option (select the text you want to copy and choose Copy Other from the Edit menu). The resulting HTML is fairly clean and, happily, uses CSS for its markup. http://www.textpad.com
Fog Creek Home