[TxMt] Re: Printing source code?

John Laudun jlaudun at mac.com
Fri Oct 3 12:34:28 UTC 2008

On Oct 3, 2008, at 7:00 AM, textmate-request at lists.macromates.com wrote:

> On Oct 3, 2008, at 1:03 PM, Ricki Gregersen wrote:
>> Hi
>> I have been looking for a way to print my recent project which is
>> around 50+ actionscript classes to
>> a single pdf for some time.
>> I tried Automater but it refuses to recognize .as files as
>> text files.
>> Is there som way to obtain this in textMate?
>> Thanks in advance:)
>> Regards Ricki
> The best thing is to generate HTML from your source code and print
> that.  In the TextMate bundle, there is a command to ?Create HTML From
> Current Document?.  Run that command and save the resulting file.
> Open in Safari and print to PDF!
> ?Alex

I would also consider using the command line tool "textutil" to  
concatenate the files and then format the catted files as RTF or HTML  
-- or even plain old text -- and then printing the compiled document.  
(You could make this an Automator script -- I know that Apple script  
allows you to call shell apps, or you could make it a bash script, or  
you could make it a Textmate command.

So many options ...

More information about the textmate mailing list