Not a biggie, but thought someone might want to know... for next time they're tinkering (Ciarán? ;-) ) with the PHP bundle.
Thought I'd try fiddling with my copy of SimpleTest to put txmt style links on the test reports, just to make things a bit easier...
Thought I'd just grab what i needed from the $message variable which shows up something like this:
[/Library/WebServer/Documents/pcs/tests/panel_test.php line 56]
Tried putting
$linkRef = preg_replace( array('/^.*[/','/].*$/','/ line /'), array('txmt://open?url=file://','', '&line='), $message);
which works as far as the links go, but throws a distinct wobbly in terms of scope within TM after that delimited open square bracket [. If I didn't happen to be searching for the end square bracket as well, then the rest of the code would be highlighted as a pattern...
Hope that's as clear as mud.
R
-- Richard Dyce MA (Cantab.) MBCS MIET
On 24 Jul 2007, at 16:41, Richard Dyce wrote:
Tried putting
$linkRef = preg_replace( array('/^.*\[/','/\].*$/','/ line /'),
array('txmt://open?url=file://','', '&line='), $message);
which works as far as the links go, but throws a distinct wobbly in terms of scope within TM after that delimited open square bracket [.
Hi Richard,
Thanks for the report.
Are you using a Subversion checkout of the PHP bundle? I've just copied and pasted that line into a PHP file and it was highlighted as I'd expect [1]
Ciarán
What I get is:
http://pastie.textmate.org/81819
Not using a subversion checkout, just the bleeding edge. Should I be?
R
On 24 Jul 2007, at 16:54, Ciarán Walsh wrote:
On 24 Jul 2007, at 16:41, Richard Dyce wrote:
Tried putting
$linkRef = preg_replace( array('/^.*\[/','/\].*$/','/
line /'), array('txmt://open?url=file://','', '&line='), $message);
which works as far as the links go, but throws a distinct wobbly in terms of scope within TM after that delimited open square bracket [.
Hi Richard,
Thanks for the report.
Are you using a Subversion checkout of the PHP bundle? I've just copied and pasted that line into a PHP file and it was highlighted as I'd expect [1]
For new threads USE THIS: textmate@lists.macromates.com (threading gets destroyed and the universe will collapse if you don't) http://lists.macromates.com/mailman/listinfo/textmate