Reloading plugins while SketchUp is running
-
@thomthom said:
@javixp said:
is is possible to load/unload/reload plugins with SketchUp running?
You can load (and reload) scripts by using the Ruby Console, typing
load 'myRubyFile.rb'
I tried that and it worked. However, what I wanted was to reload plugins using... another plugin, something like this:
def reload load 'myRubyFile.rb' end
Problem is that one doesn't work, the Ruby Console says:
C;/Program Files (x86)/Google/Google SketchUp 8/Plugins/myRubyFile.rb;64;in `load' C;/Program Files (x86)/Google/Google SketchUp 8/Plugins/myRubyFile.rb;64 C;/Program Files (x86)/Google/Google SketchUp 8/Plugins/myRubyFile.rb;64;in `call' C;/Program Files (x86)/Google/Google SketchUp 8/Plugins/myRubyFile.rb;64
Note: Line 64 is where the function 'reload' is called
Thanks
-
You must replace myRubyFile.rb with the actual filename of the plugin you want to reload. I just picked a random name...
-
I know, I know. I think you didn't understand me well
It does work on the ruby console, but not as a plugin itself.
-
You cannot load the file itself while it's being loaded. (.. it's a circular reference.)
The load call must be made from another file.
-
That fixed the 'issue', thanks
Advertisement