[TxMt] Re: Generate new HTML doc from parsed PHP?

Michael Reiner mr at radarseven.com
Thu Oct 23 22:18:00 UTC 2008


Sven,

Thanks for your help...
Can you clarify your solution just a bit?
I'm a command line beginner and am just a bit confused on how to  
implement this.
Where is the executable stored (Applications?) and then how do I call  
the command, I'm assuming from a Terminal window?
Does the executable need to be in the same directory? I tried this but  
I was getting the command not found error in Terminal.

Thanks again for your help.


On Oct 23, 2008, at 5:36 PM, Sven Axelsson wrote:

> 2008/10/23 Michael Reiner <mr at radarseven.com>
> Most excellent, thanks Sven!
> Didn't know this functionality existed in a Terminal session!
> This is exactly what I needed.
>
> Now I just need to figure out how to write a simle bundle to  
> automate the process a bit,
> i.e. create a bundle that will output the current file to an HTML  
> file with the same name and in the same directory.
> Any insight or resources that could point me in the right direction?
>
> Try putting this in a text file:
>
> php "$1" > `dirname "$1"`/`basename "$1" php`html
>
> Save it under some convenient name, like do_convert
> call chmod +x do_convert to make it executable
>
> and use it like:
>
> do_convert some_file.php
>
> that will save some_file.html in the same directory as the input file
>
> -- 
> Sven Axelsson
> ++++++++++[>++++++++++>+++++++++++>++++++++++>++++++
> >++++<<<<<-]>++++.+.++++.>+++++.>+.<<-.>>+.>++++.<<.
> +++.>-.<<++.>>----.<++.>>>++++++.<<<<.>>++++.<----.
>
> _______________________________________________
> textmate mailing list
> textmate at lists.macromates.com
> http://lists.macromates.com/listinfo/textmate

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macromates.com/textmate/attachments/20081023/968c7669/attachment.html>


More information about the textmate mailing list