Rhino Script Compiler for Rhino5, second Beta

Hi All,

I can’t find a way to define a version of the plugin. I thought I saw it before in the script compiler but not there; I also looked at RHI guidelines on WIKI: http://developer.rhino3d.com/guides/rhinocommon/plugin_installers_windows/

So after making the RHI out of zipped folder of the plugin I am testing I always get version 1.0.0.0 C:\Program Files\Common Files\McNeel\Rhinoceros\5.0\Plug-ins\MyPlugin\1.0.0.0

Where can I control the version number ?

thanks,

–jarek

Anyone ?

The version information needs to be compiled into the plug-in itself. The RHI system doesn’t have control over what version a plug-in is.

It doesn’t look like the compiler currently has support for setting a version. You would need to have the compiler generate the source files for you; add the version information and then compile with Visual Studio.

Thanks Steve. I’d add the version setting to the compiler wish pile.

–jarek

Done
https://mcneel.myjetbrains.com/youtrack/issue/RH-35623

@Jarek,

not sure if this helps, using the new compiler i put my plugin version information at the end of the start up message so i can at least check if updating the plugin worked or if the old version is still loading.

@stevebaer, i do miss the licensing and menu options which where available in the old compiler. Will something like this be considered in the future ?

c.

Thanks Clement, that’s a great suggestion. What I was trying to figure out and test is how the *.rhi installer recognizes and always installs the latest plugin version, (per wiki instructions). Now can’t do it unless manually compiling as Steve suggested.

Hi @stevebaer,

Since it is an anniversary of last activity on this bug report, I will try again and say that the current problem with compiled scripts not running inside transparent commands is quite a pain and makes a lot of compiled plugins over here much less useful…
https://mcneel.myjetbrains.com/youtrack/issue/RH-31820
Hope for some love for this one in 2017 !

–jarek

Let’s hope so. :wink:

Let’s! Maybe this one could jump into your pile then ? :wink:

1 Like

Can the compiler fuse this RUI-toolbar file I’ve create into the RHI-file automatically or will I have to rename it to zip, add the rui-file and the rename it back manually?

You’ll need to do the work manually for now. We can add this type of functionality in a future version of the compiler

Hi everyone,

It’s been a while since we have discussed this topic but I have an issue and I think you might be able to help me out.

Currently, my plug-in compilation process is finalized using scripts, and now I would like to automatize all that by using Jenkins. So I basically transferred my batch scripts and everything seems to work fine except for the compilation of my RHP with the RhinoScriptCompiler.exe, let me explain why.

It seems that the executable assumes that it has a “physical” console window opened and it tries to rescale it or at least graphically interact with it, which leads to a crash in Jenkins which is working in batch.

c:\test_jenkins\jenkins_workspace\workspace\RhinoPlugin>RhinoScriptCompiler.exe .\test.rhc 

Unhandled Exception: System.IO.IOException: The handle is invalid.

   at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
   at System.IO.__Error.WinIOError()
   at System.Console.set_CursorVisible(Boolean value)
   at RhinoScriptCompiler.Program.Main(String[] args)

When I try to do that manually on the physical machine (via RDP) in the console it works fine.

Do you think it could be possible to handle this case?
Is there a “full batch mode” for the RhinoScriptCompiler.exe?
Is the source code of the RhinoScriptCompiler.exe accessible?

Thanks in advance for your help!

Best regards,
Nathan

In my code :
Call Main()
Sub Main()
Dim objXL
Set objXL = CreateObject(“Excel.Application”)
objXL.Visible = True
Call objXL.WorkBooks.Open(“D:\CUA”)
’ GAN GIA TRI TRONG EXCEL CHO BIEN
Dim i, A(12)
For i = 1 To 12 Step 1
A(i) = objXL.Worksheets(1).Cells(2 + i, 4).Value
Next
Rhino.print A(7)
End Sub
It is Ok
But after I use RhinoScript compiler and run it had error1
Help me.

Hi,
Do you close your file after creating it?
If not then that could explain why you can’t read it it

@stevebaer, i just re-post 3 wishes here in the hope that the compiler can get some love in the future:

  1. Please support / allow to include python modules
  2. Please allow to include custom files in the compiled rhi (rui, chm, pdf files etc)
  3. Please allow to control the compiled plugin version number

thank you,
c.

4 Likes

hi Clement,

Maybe i misunderstand, but currently it is possible. RHI is just renamed ZIP, so if you open it using zip software, you can add any files you want. Or compile to rhp, and zip together with your files, then rename to rhi.

EDIT: unless you ask for ability to pick files from compiler project level for better automation. That indeed would be handy!

–jarek

Hi @Jarek, that is the reason. Currently it makes a lot of work to update a plugin made of multiple scripts and other files without making errors. The most useful addition would be modules. I have a plugin with a dozen scripts which could all access a single module. To compile the scripts, i need to copy the module code into every script. If i update the module i need to repeat this again, so i have 2 versions of all scripts, the ones which are compilable (having the module code) and the ones which are not compileable and access the module in a regular way.

If i just could recompile the project and all files (scripts, chm, pdf…) referenced in my rhc project would be taken automatically, it would save a lot of time.

_
c.

2 Likes

yeah, definitely! I also would find that very useful to automate packaging scripted plugins.

RH-35623 and RH-57990 are fixed in the latest WIP