hi there - I'm trying to make a simple macro that will perform the 'Open in Running Browser' operation *and then actually switch window focus over to the open page in the browser*! it's a bit strange that TM doesn't do this automatically but whatever. I tried making a simple little macro so I could just code it in by hand but I'm not proficient enough with whatever scripting language TM uses for it's macros (Ruby?) anyway, mayhap there is a simple solution to this? it seems like there should be! cheers, bennett
On Mon, Jun 21, 2010 at 00:26, plastichairdoo plastichairdoo@gmail.com wrote:
hi there - I'm trying to make a simple macro that will perform the 'Open in Running Browser' operation *and then actually switch window focus over to the open page in the browser*! it's a bit strange that TM doesn't do this automatically but whatever. I tried making a simple little macro so I could just code it in by hand but I'm not proficient enough with whatever scripting language TM uses for it's macros (Ruby?) anyway, mayhap there is a simple solution to this? it seems like there should be!
In the script, do you see the line reading # On Leopard use the -g option to open in background. Maybe you could try removing the -g option from the call to `open` below it?
HTH, Martin
found those lines and removed the -g parameter from the command - left with this:
------------CODE------------
# TODO: Change when Leopard Only # On Leopard use the -g option to open in background. if os =~ /^10.(5|6)/ active.each {|p| `open -a #{e_sh(p)} #{e_sh(url)}` } else active.each {|p| `open -a #{e_sh(p)} #{e_sh(url)}` } end</string>
------------CODE------------
didn't work :( any other advice? b
On Jun 20, 2010, at 3:34 PM, Martin Kühl wrote:
On Mon, Jun 21, 2010 at 00:26, plastichairdoo plastichairdoo@gmail.com wrote:
hi there - I'm trying to make a simple macro that will perform the 'Open in Running Browser' operation *and then actually switch window focus over to the open page in the browser*! it's a bit strange that TM doesn't do this automatically but whatever. I tried making a simple little macro so I could just code it in by hand but I'm not proficient enough with whatever scripting language TM uses for it's macros (Ruby?) anyway, mayhap there is a simple solution to this? it seems like there should be!
In the script, do you see the line reading # On Leopard use the -g option to open in background. Maybe you could try removing the -g option from the call to `open` below it?
HTH, Martin
textmate mailing list textmate@lists.macromates.com http://lists.macromates.com/listinfo/textmate
On Mon, Jun 21, 2010 at 00:52, plastichairdoo plastichairdoo@gmail.com wrote:
found those lines and removed the -g parameter from the command - left with this:
------------CODE------------
# TODO: Change when Leopard Only # On Leopard use the -g option to open in background. if os =~ /^10.(5|6)/ active.each {|p| `open -a #{e_sh(p)} #{e_sh(url)}` } else active.each {|p| `open -a #{e_sh(p)} #{e_sh(url)}` } end</string>
------------CODE------------
didn't work :( any other advice? b
Just the obvious one: Did you close the Bundle Editor (or load another item with it) to make sure the new version actually gets used? /mk
yes - but just to be sure I quit and relaunched. I should add that I'm not completely sure if I'm importing the macro correctly. in order to edit it I dragged it out of the Bundle Editor to the desktop and then opened it in Text Wrangler (sacrilege!) after I made the changes I then double clicked it in the Finder and clicked "Yes" when it asked me whether I wanted to update the command etc.
was that right?
thanks for your help BTW b
On Jun 20, 2010, at 4:10 PM, Martin Kühl wrote:
On Mon, Jun 21, 2010 at 00:52, plastichairdoo plastichairdoo@gmail.com wrote:
found those lines and removed the -g parameter from the command - left with this:
------------CODE------------
# TODO: Change when Leopard Only # On Leopard use the -g option to open in background. if os =~ /^10.(5|6)/ active.each {|p| `open -a #{e_sh(p)} #{e_sh(url)}` } else active.each {|p| `open -a #{e_sh(p)} #{e_sh(url)}` } end</string>
------------CODE------------
didn't work :( any other advice? b
Just the obvious one: Did you close the Bundle Editor (or load another item with it) to make sure the new version actually gets used? /mk
textmate mailing list textmate@lists.macromates.com http://lists.macromates.com/listinfo/textmate
On Mon, Jun 21, 2010 at 02:36, plastichairdoo plastichairdoo@gmail.com wrote:
yes - but just to be sure I quit and relaunched.
Huh, strangeness. The same change works for me, and I can't see why it would open anything in the background afterwards…
I should add that I'm not completely sure if I'm importing the macro correctly. in order to edit it I dragged it out of the Bundle Editor to the desktop and then opened it in Text Wrangler (sacrilege!) after I made the changes I then double clicked it in the Finder and clicked "Yes" when it asked me whether I wanted to update the command etc.
I think that should work. You can make sure by checking the script in the Bundle Editor. By the way, a nicer way to edit commands is to install the “Edit in TextMate” thingy (or something “similar” like QuickCursor) and invoke it from the Bundle Editor. That way you can edit those scripts in TextMate as if they were regular files.
thanks for your help BTW
You’re welcome. :-)
But sorry, I can't think of anything else. Martin
On 21 Jun 2010, at 02:36, plastichairdoo wrote:
[...] I dragged it out of the Bundle Editor to the desktop and then opened it in Text Wrangler (sacrilege!) after I made the changes I then double clicked it in the Finder and clicked "Yes" when it asked me whether I wanted to update the command etc.
was that right?
Why not just edit it directly in the bundle editor? You basically made a copy, edited that as raw XML in another application, and re-imported it, and since it should work w/o the -g option, it sounds like something did go wrong in the process.
Macro says "Read Only" at the top - when I click on the executeCommandWithOptions" I see the raw command code but am unable to edit.
On Jun 21, 2010, at 12:45 AM, Allan Odgaard wrote:
On 21 Jun 2010, at 02:36, plastichairdoo wrote:
[...] I dragged it out of the Bundle Editor to the desktop and then opened it in Text Wrangler (sacrilege!) after I made the changes I then double clicked it in the Finder and clicked "Yes" when it asked me whether I wanted to update the command etc.
was that right?
Why not just edit it directly in the bundle editor? You basically made a copy, edited that as raw XML in another application, and re-imported it, and since it should work w/o the -g option, it sounds like something did go wrong in the process.
textmate mailing list textmate@lists.macromates.com http://lists.macromates.com/listinfo/textmate
On 21 Jun 2010, at 17:38, plastichairdoo wrote:
Macro says "Read Only" at the top - when I click on the executeCommandWithOptions" I see the raw command code but am unable to edit.
Ah, sorry. Didin’t realize it was a *real* macro you wanted to edit, since you quoted ruby code (just thought you had the terminology mixed up).
For me though the ‘Open Document in Running Browser(s)’ action is a *command* and it *is* editable int he bundle editor.
So I think this mixup is where your problem lies.
What you may want to do is first revert your customizations: http://wiki.macromates.com/Troubleshooting/RevertToDefaultBundles
Relaunch TextMate, go to the bundle editor, locate the ‘Open Document in Running Browser(s)’ *command* and remove the ‘-g’ *in the bundle editor*.
Close bundle editor and see if that doesn’t fix it for you.
hi there - I appreciate the help but I really would rather not reset the bundles to their defaults as I have customized about 100 of the snippets! I suppose I could export and then selectively import but I'd much rather just get a copy of this single Command/Macro and import IT!
I checked in the Subversion Bundles and couldn't find any Bundle with the 'Open in Browser' command...
could someone email me theirs perhaps? I had decided it wasn't that big of a deal for the moment but now I've changed my mind - it's driving me a bit crazy!
oh - one more unrelated query: is it possible to change the way TM handles its 'spacing'? by which I mean this: if I click my mouse in a document in any other text editor if there is no text on a line the caret ends up at the beginning of the line - but in TM if I click in the middle of the page on a new line the caret appears right where I click, and then if I try to backspace to go to the beginning of the line it will only backspace a single character - so I then have to opt-backspace etc etc it's strange and not really standard behavior for a text editor in my experience. also if I am at the beginning of a new line and I tab in and then backspace rather than the caret returning immediately to the beginning of the line it only backspaces one space. and lastly - how come the cmd-backspace shortcut doesn't work in TM? in all other apps it jumps to beginning of the line.
anyway, sorry if some of that is not too clear. please let me know I need to clarify.
it seems like I have some kind of setting set incorrectly. probably pilot error after all. =7 thanks, bennett
On Jun 21, 2010, at 8:55 AM, Allan Odgaard wrote:
On 21 Jun 2010, at 17:38, plastichairdoo wrote:
Macro says "Read Only" at the top - when I click on the executeCommandWithOptions" I see the raw command code but am unable to edit.
Ah, sorry. Didin’t realize it was a *real* macro you wanted to edit, since you quoted ruby code (just thought you had the terminology mixed up).
For me though the ‘Open Document in Running Browser(s)’ action is a *command* and it *is* editable int he bundle editor.
So I think this mixup is where your problem lies.
What you may want to do is first revert your customizations: http://wiki.macromates.com/Troubleshooting/RevertToDefaultBundles
Relaunch TextMate, go to the bundle editor, locate the ‘Open Document in Running Browser(s)’ *command* and remove the ‘-g’ *in the bundle editor*.
Close bundle editor and see if that doesn’t fix it for you.
textmate mailing list textmate@lists.macromates.com http://lists.macromates.com/listinfo/textmate
plastichairdoo wrote:
it's strange and not really standard behavior for a text editor in my experience. also if I am at the beginning of a new line and I tab in and then backspace rather than the caret returning immediately to the beginning of the line it only backspaces one space.
You have "Freehanded Editing" turned on (see TextMate=>Edit=>Mode). Maybe you hit command-option-e by mistake at some point...
Cheers, Paul
aha! I knew it was pilot error! thanks!
btw - I managed to find the GetBundles Bundle and using that I installed all the bundles I need and then some! I went a little crazy actually... I'm kind of a plugin maniac =7 b
On Jun 26, 2010, at 7:30 PM, Paul McCann wrote:
plastichairdoo wrote:
it's strange and not really standard behavior for a text editor in my experience. also if I am at the beginning of a new line and I tab in and then backspace rather than the caret returning immediately to the beginning of the line it only backspaces one space.
You have "Freehanded Editing" turned on (see TextMate=>Edit=>Mode). Maybe you hit command-option-e by mistake at some point...
Cheers, Paul
textmate mailing list textmate@lists.macromates.com http://lists.macromates.com/listinfo/textmate
I am using TextMate with R. Send Selection/Document to R.App works nicely from the dropdown command menu. There, it also says that Cmd-Option-Shft-R should do this, but it doesn't. What am I doing wrong here?
-- Erich Neuwirth, University of Vienna Faculty of Computer Science Center for Computer Science Didactics and Learning Research Visit our SunSITE at http://sunsite.univie.ac.at Phone: +43-1-4277-39902 Fax: +43-1-4277-39459
OK, once again I was not fully awake. When the cursor is not in the textmate window, of course the keyboard showrdcut does not work, I had selected R as the active application with the mouse.
On Jun 28, 2010, at 7:53 PM, Erich Neuwirth wrote:
I am using TextMate with R. Send Selection/Document to R.App works nicely from the dropdown command menu. There, it also says that Cmd-Option-Shft-R should do this, but it doesn't. What am I doing wrong here?
-- Erich Neuwirth, University of Vienna Faculty of Computer Science Center for Computer Science Didactics and Learning Research Visit our SunSITE at http://sunsite.univie.ac.at Phone: +43-1-4277-39902 Fax: +43-1-4277-39459
textmate mailing list textmate@lists.macromates.com http://lists.macromates.com/listinfo/textmate
-- Erich Neuwirth, University of Vienna Faculty of Computer Science Center for Computer Science Didactics and Learning Research Visit our SunSITE at http://sunsite.univie.ac.at Phone: +43-1-4277-39902 Fax: +43-1-4277-39459