Yes it does, take your directory of files, and drop it onto the TextMate icon, 
this will create a "project" of all your files and directories.

You can then go to Edit -> Find in Project and issue the regex that Ryan 
suggested.  I do not believe changes are committed until you save the project, 
or close the project window.

You could also cheat, if you did not want to use a regex.  First, find the 
opening php tag:

find <?php
replace <temp-php-1234

Next find
<?
replace <?php

Finally find
<temp-php-1234
replace <?php

That is a more manual and gross way to do it, but it does work, and is often a 
simple way to find and replace strings that contain other strings.  I used 1234 
to make sure it is unique to the files, you can use any string you want, just 
so long as you are 100% sure that replace string is not used anywhere in the 
files.
-- 
Scott * If you contact me off list replace talklists@ with scott@ * 

On Jan 17, 2010, at 2:20 AM, Jasper Frumau wrote:

> TextMate's search and replace does not seem to offer a search and replace
> across multiple files that is precise enough. I need to replace <? by <?php
> and <? only.  When I look for <? I get <?php as well. I am looking into a
> neat command to do it as well as TextWrangler.

_______________________________________________
macports-users mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macports-users

Reply via email to