Merge Nested Groups down into a single group

Well, there is a way to make this a plug-in - I haven’t really dealt with that - but the easiest way for me is to do the following:

  1. Save the script somewhere known - like
    C:\Users\<username>\AppData\Roaming\McNeel\Rhinoceros\5.0\scripts

  2. Manually create an alias:
    ! _RunPythonScript "C:\Users\<username>\AppData\Roaming\McNeel\Rhinoceros\5.0\scripts\RegroupObjects.py"

When you type the alias, it will run.

If you are going to do this with a bunch of scripts:

In the Python editor (_EditPythonScript), under Tools>Options, Files tab, set a path to the folder where you will keep all your scripts. Then in your aliases, all you need to have is:

! _RunPythonScript "Scriptname"

The script module will go looking to see if there is a script by that name in the search path, so you do not need to put in the absolute path. This is also good if you later decide to change the folder name or location, all you need to do is re-set the script path in the editor, not change all your aliases.

–Mitch