[TxMt] Re: Web preview enhancements?
Thomas Aylott / subtleGradient
textmate at subtlegradient.com
Fri Jul 4 15:16:44 UTC 2008
Update the bundle and try again. I just fixed that error.
For best awesomeness you can set the variables $TM_PROJECT_SITEROOT
and $TM_PROJECT_SITEURL
so that if you're testing PHP or rails or something it'll preview
through your server.
Also, you can manually add any random url you want into the file
'/tmp/42_tm_css_live_preview_url.stupid_way_to_save_info'
I named the temp file that because I hadn't thought of anything else
at the time and wanted to remind myself how stupid this method is.
Still works though.
In the Web Preview window you can use variables in the path, so you
could setup something like: "$HOME/Library/Application
Support/TextMate/Bundles/subtleGradient.tmBundle/Support/bin/42_TextMate_live_preview.rb"
if you have the bundle installed in "$HOME/Library/Application
Support/TextMate/Bundles/"
huh, I wonder if you could set the preview command path to a variable
and then set that variable dynamically. Could be a cool. I'll fiddle
with it.
On Thu, Jul 3, 2008 at 10:34 AM, Marco De Vitis <starless at spin.it> wrote:
> Il 3-07-2008 7:05, Thomas Aylott / subtleGradient ha scritto:
>
>> My "Leopard Dark 2" GUI replacement
>> http://wiki.macromates.com/Main/AlternativeGUIs does help a bit.
>
> Thanks, I installed it and it's cool ;), but in what regard does it
> help? You mean for having the same fonts as Safari in the web preview?
>
>> Also check out my subtleGradient.tmbundle on GitHub:
>> http://github.com/subtleGradient/subtlegradient-tmbundle/tree/master
>>
>> If you set up the
>> subtlegradient.tmbundle/Support/bin/42_TextMate_live_preview.rb file
>> as your filter through command in the web preview window you can get
>> live html and CSS previews. You have to set the url to use for
>> previewing css first. There's a command to do that for you too.
>
> Uhm, I did it, and I think I found the command you mention, but I must
> be missing something. How should I proceed to get my HTML page preview
> while editing the related CSS?
> I tried opening the CSS, then the HTML in a different tab, then while on
> the HTML file selecting the "Use this page as the CSS preview" bundle
> command, but I get an error popup:
>
> /Applications/TextMate.app/Contents/SharedSupport/Support/lib/escape.rb:23:in
> `e_url': private method `gsub' called for nil:NilClass (NoMethodError)
> from /tmp/temp_textmate.44nGg5:5
>
> --
> Ciao,
> Marco.
>
>
> _______________________________________________
> textmate mailing list
> textmate at lists.macromates.com
> http://lists.macromates.com/listinfo/textmate
>
--
Thomas Aylott
subtleGradient.com
More information about the textmate
mailing list