Hi all,
There were a couple of bugs in the Snippets, Commands, Macros and Languages bundled with 1.0 (What can I say, I was in a rush!).
I'd like to use this thread to document any problems you've encountered or suggestions you have specifically in regards to the Bundles. Please, no feature requests, or anything related to the general TM application.
Here's what I have so far:
Snippets: - br and hr snippets are redundant (use "Make HTML Tag 2" command instead) - meta snippet didn't have any placeholders - PHP function snippet didn't have a placeholder for the function name - The three PHP tag openers are a little much... will make one redundant, and people can customise top suit their own preferences
Languages: - swapped SCRIPT and STYLE patterns around the wrong way in HTML.plist
Macros: - nothing yet
Commands: - rename "Reload in Safari" to "Refresh Safari", since that's all it does - add a php.net manual look-up command for the current word
I'd appreciate any suggestions for more snippets, macros and commands to add to the default set. Please keep them all in this thread, so it's easy for me to keep track of what's going on. Anything that can help people speed up their productivity or solve repetitive or boring tasks is a great candidate.
Justin French
On Oct 6, 2004, at 11:34 PM, Justin French wrote:
Languages:
The syntax coloring for Ruby could use a bit more love:
Instance variables (@foo) and class variables (@@foo) would be nice to have in a different color.
There's no support for %q|...|, %Q|...|, %Q{...}, etc. type strings, nor %r{...} type regexps. (Perhaps because they're difficult, if not impossible, to specify in a regexp without recursive support.)
There's no support for 'here-document' strings. -- (-, /\ / / //
On 7/10-2004, at 14:47, Gavin Kistner wrote:
There's no support for 'here-document' strings.
Heredoc requires a slightly more general form of the begin-end style matches. Either the carrying over of captures from begin to end, or (perhabs even better), some general system for using various values (including begin-captures) in the rest of the rule. I believe this is on a todo for an upcomming update.
Justin,
Languages:
When editing Ruby code, everything after the first "/" in code turns yellow. For example, in the code
class Foo def bletch(num) @foo = num / 12 end end
everything from the "/" to the end of the file is yellow.
Jim
Justin - your (?) link making macro (control-shift-l) misbehaves I think:
If all there is only one word in your file it works fine - about (control-shift-l) makes <a href="about.html">about</a>, but when there is more then one word in the file your macro works on all the lines - turning -v
<html> <head> <title>test page, what?</title> </head> <body> about </body>
into -v
<a href="<html>.html"><html></a><a href=".html"></a> <a href="<head>.html"><head></a><a href=".html"></a> <a href=" <title>test page, what?</title>.html"> <title>test page, what?</title></a><a href=".html"></a> <a href=" </head>.html"> </head></a><a href=".html"></a> <a href="<body>.html"><body></a><a href=".html"></a> <a href="about.html">about</a><a href=".html"></a> <a href="</body>.html"></body></a>
On 08/10/2004, at 5:30 AM, Kjell Olsen wrote:
Justin - your (?) link making macro (control-shift-l) misbehaves I think:
it's mine and Allan's :)
If all there is only one word in your file it works fine - about (control-shift-l) makes <a href="about.html">about</a>, but when there is more then one word in the file your macro works on all the lines - turning -v
It only works when you have text selected, otherwise, yes, it does the whole file... I'll see if we can do a check for a selected text.
Justin
On 8.10.2004, at 05:05, Justin French wrote:
It only works when you have text selected, otherwise, yes, it does the whole file... I'll see if we can do a check for a selected text.
Justin,
One quick fix would be to add alt-w to the beginning of the macro. If there is a selection at hand, the command doesn't do anything (so the selection keeps intact), but if there's no selection, it selects the word you were typing. I think this is the behavior you'd want in 99% of the cases and at least you'd get rid of the "select the whole file" bug.
I've used the trick in all of my macros (that it suits) and have had no problems with it.
//jarkko -- Jarkko Laine http://jlaine.net http://divingfinn.blogspot.com
On 08/10/2004, at 7:28 PM, Jarkko Laine wrote:
On 8.10.2004, at 05:05, Justin French wrote:
It only works when you have text selected, otherwise, yes, it does the whole file... I'll see if we can do a check for a selected text.
Justin,
One quick fix would be to add alt-w to the beginning of the macro. If there is a selection at hand, the command doesn't do anything (so the selection keeps intact), but if there's no selection, it selects the word you were typing. I think this is the behavior you'd want in 99% of the cases and at least you'd get rid of the "select the whole file" bug.
I've used the trick in all of my macros (that it suits) and have had no problems with it.
Duly noted, and it's in 1.0.1 whenever that gets released :)
Justin