[Plugin] Debug tool: run lastloaded ruby

[Plugin] Debug tool: run lastloaded ruby

Postby liquid98 » Sun Mar 25, 2012 10:11 am

Hi!

This plugin simplifies the debugging process with a few mouse clicks. It works in conjunction with Jim Foltz' rubytoolbar, which can be found here:

http://sketchuptips.blogspot.com/2007/08/plugin-ruby-toolbar.html

Once you've loaded the script you want to debug through the rubytoolbar, you can simply reload and execute your script in one step.

How does it work?

Lastloaded.rb looks for a line in your code tagged with:
Code: Select all
#loadme
So just put this string after the line in your code that Sketchup has to execute.
For example:

Code: Select all
new_menu = UI.menu("Plugins")
cmd = UI::Command.new("text") {some command} #loadme
new_menu.add_item(cmd) 


Lastloaded will now reload your script and automatically runs 'some command' for you. The script has a menu item in the Tools section, so you can assign a shortcut if convenient.


Have fun! I'm open for questions / suggestions
0
Things that flourish fall into decay. This is not-Tao, And what is not-Tao soon ends ~ Lao tse
User avatar
liquid98 
 

SketchUcation One-Liner Adverts

by Ad Machine » 5 minutes ago



Ad Machine 
Robot
 


 

Return to Plugins

Who is online

Users browsing this forum: Chc, erichz, mikempr2000, pibuz and 10 guests

Visit our sponsors: