Loading Ruby Scripts
-
How exactly do you load a new ruby (.rb) file. I have tried copying some into the plugin's folder...some work...some do not. Just wondering if any one can lead me in the proper direction.
Thanks - Tim
-
That is exactly what you do.
Remember, some show up in the Plugins menu, some in Tools also Draw and Context click. It all depends on which Ruby you installed.
Also remember, some of the Rubies with a toolbar will require you to go to Window/Preferences/Extensions to turn on their toolbar/icon. -
Hi Tim,
As Dylan says, there can be one or more access points for a plugin (aka. script, ruby.) A script can add a menu-item to any of the available menus, it can add a sub-menu with multiple child Menu items, it can add a Toolbar accessible under the View > Toolbars menu, it can use a context (right-click) menu, and finally it can make itself available in the Windows > Preferences > Extensions dialog.
Once you get the .rb file into the Plugins folder, the easiest way to load it is to close and restart SketchUp. If you don't want to close SketchUp, you can load the file by opening the Window > Ruby Console, and entering:
load "script_name.rb"
(but replacing "script_name.rb" with the filename of the .rb file you've installed.) This is also a good way to do it if you are having trouble with a script because you can see any error messages that would prevent the plugin from being loaded.
Advertisement