TeXShop has a neat solution for this: it lets you set a master
document manually (which is no big deal for larger projects). This
way, if you hit LaTeX in any of the documents, the master documents
gets LaTeXed. This should be a piece of cake to add to TextMate …
although I still use TeXShop to compile and check my LaTeX documents.
Max
> On 27/5/2006, at 16:03, Aristide Grange wrote:
>
> > Thank you for having explained me how to solve this stupid-but-big
> > problem with search/replace in TextMate! [...]
>
> Just FYI the problem comes not from stupid code but from data
> structure trade-offs.
Thank you for your very interesting explanations about the data
structure you use. My intervention on the topic was initially
motivated by the fact that Chris mentioned the same (stupid) problem
on a 3.7MB XML file:
> The big mistake was to try and do a Find/Replace of all ">" with ">
> \n".
> Whoah. It's been using all the CPU and beachballing for over 30
> minutes now,
> with no obvious way to interrupt it...
From my point of view, the problem of Chris was including two
independant matters: 1. slow global replacement; 2. global reparsing.
I was surprised that your reply to him (well, the kind one) focused
almost only on parser considerations. It was not perfectly clear for
me that your promise of future improvements on "half a dozen other
things which do affect the performance" included the one I care
about. So, I thought it was necessary to insulate the first problem,
with which I have to deal on a daily basis: global replacement on
plain text. Obviously, I knew it had "nothing to do with the language
parser": it was precisely my point...
Then, Paul came with a great solution to this very problem: filter
the document through a magic perl command. Since them, I am happy,
and I guess TextWrangler will not encuber my dock for a long time now.
But his reply makes a second (probably stupid too) question to pop
into my mind: since there is such a performance issue with the
builtin global replacement of TextMate, why not just delegate the
work to perl, directly from the shiny and so convenient Find window?
And if, for some reason, it is not always possible, why not offer
this as an option through some cute check box?
Concerning the "marketing" considerations of Daniel, I second that.
My own experience, as an old BB et al. registered user, is the
following: in the past, I have given TextMate at least three (too)
short tries. Each time, I thought: "it is not for me, because 1.
there is no incremental search; 2. global replacement is too slow".
The drawback with TextMate is that its real superiority and its
amazing features are not very prominent. This "tact" has several very
important advantages too, e.g., the interface is not bloated and the
learning curve is so smooth. But I have had to force me to try
TextMate during one plain week *before* I finally fall in love with
it. BTW, I don't remember if I registered before or after I
accidentally discovered it does offer incremental search (the manual
is rather allusive on this point). So I think it would be a killer
marketing idea to help the switchers to figure out how they can use
TextMate as efficiently as their favourite text editor. Apple has
made something like that for the Windows users (and we all know that
Apple never makes any marketing error ;-). Perharps some dedicated
annex in the documentation?
Cheers,
A.
Originally when I installed Textmate it offered to put in the link for the
"mate" command which I chose to do. The mate command worked from terminal
until the next day when I fired up my computer and suddenly it stopped
working. So I went into the "Help" menu, "Terminal "Usage" option and
clicked the "Create Link" button for /opt/local/bin, it gives me an error
"Couldn't create link: /opt/local/bin/mate filed ... bad address". If it
use any of the other paths I get an error the the operation is not
permitted.
Not sure what to do. Isn't mate just a symbolic link to the actual
textmate.app in applications?
Thanks for nay help on this.
> Actually, I didn't do it correct there either :)
>
> osascript &>/dev/null \
> -e 'tell app "Backdrop" to activate' \
> -e 'tell app "MenuShade" to activate' \
> -e 'tell app "TextMate" to activate' &
Fantastic, works great.
> Sorry, should have been:
>
> osascript 2>/dev/null \
> -e 'tell app "Backdrop" to activate' \
> -e 'tell app "MenuShade" to activate' \
> -e 'tell app "TextMate" to activate' &
Wow, that is totally bizarre.
The only way this DOESN'T hang TextMate is if I set the Output to
"Show as HTML". Ideally, I'd discard it, but that hangs the app.
Bizarre.
I tried the following command:
osascript -e 'tell app "Backdrop" to activate'
osascript -e 'tell app "MenuShade" to activate'
osascript -e 'tell app "TextMate" to activate'
which causes TextMate to hang because (as Allan told me)...
> because you send an event to TM, but TM won't respond as
> it is busy executing the command, so the command will stall
> (waiting for TM, which waits for the command.)
He suggested:
> osascript 2>/dev/null & \
> -e 'tell app "Backdrop" to activate' \
> -e 'tell app "MenuShade" to activate' \
> -e 'tell app "TextMate" to activate'
Which returns the following error:
> /bin/bash: line 2: -e: command not found
So I ask you who know more than I, what is the key to unlocking this one?
Thanks in advance.
> Text => Filter through command...
> perl -pe 's#~\n#\n#'
Dear Paul,
Thank you for having explained me how to solve this stupid-but-big
problem with search/replace in TextMate! The workaround you suggest
works fine and faster than TextWrangler. And, believe it or not, I
would not have found it alone: my command-line skills are beyond
mediocrity. However, I suspected I missed something...
:-)
I hope your kind answer will help some other newbies too.
Thanks again!
A.
This may have gotten lost in the last thread, but with the new
~/Library/Application Support/TextMate/Pristine Copy/Bundles folder,
where is the best place to check out the bundles/themes/plugins from
http://macromates.com/svn/Bundles/trunk ?
The directions say to check them out to /Library/Application
Support/Textmate, but the release notes (and Allan's previous email),
said the place for new bundles is the "Pristine Copy" folder. Is that
folder just for bundles? What about the rest of the items that are
currently in /Library/Application Support.... ?
(now I do:
cd /Library/Application Support/Textmate
svn up
to update. Should I move that TextMate folder into.. um... ?? and svn up there?)
Thanks!
John
I'm checking out Textmate as a screenwriting application, using the
screenwriting bundle. It looks great, and fast, and cheap. But I have a
couple of questions. Apologies if they're old chestnuts and please point
me to archive posts, wiki or whatever if that's where the answer lies.
1. I'm using a 12 inch iBook and the mandatory font for screenwriting
(believe me it is mandatory, and using a different one isn't a
possibility) is Courier 12pt. However it's uncomfortably small on my
screen. Is there anyway of zooming it up a bit, or do I have to just use
a larger font size for editing then whack it down again when I print?
Not a disaster if that's the only answer, but I'd like to know if
there's a way round it.
2. I've imported a Final Draft script from a text file, and the
'dialogue' paragraphs need new formatting applying. From a brief fiddle
around, it looks like every paragraph needs changing to the 'style' (not
quite sure if this is the right terminology, but I hope you know what I
mean), then reformatting - ie ctrl-4 then ctrl-q in the screenplay
bundle. I'd *really* like not to have to do this manually. Is there a
search-and-replace stylee way of automating it.
All help and suggestions welcomed.
Matt Hurst