This action supports automating the download and installation of the latest published Rhino3d service release onto Windows runners. The objective is to facilitate the setup of Rhino for automated workflows such as CI and automated testing.
- Downloads the latest Rhino for Windows (8 at the time of writing) service release installer.
- Installs the downloaded Rhino installer.
- This action does not do anything related to licensing Rhino, either with a Core-Hour Billing Token or Rhino Account.
- This action does not do anything related to automatically running Rhino.
- This action does not do anything related to automated testing.
- This action does not allow you to specify a Rhino version.
# ...
jobs:
build:
- name: Install Rhino
uses: mcneel/setup-rhino3d@v2
with:
email-address: ${{ secrets.EMAIL_ADDRESS }}
release-version: rc # see below for values
# ...
Required The email of the associated user.
Note
It is recommended that you save this email address as a repository secret. For more information on setting up repository secrets, see this article.
Optional The release version you wish to use. Values include:
- latest - The default. If no release-version is specified, this is what is used.
- rc - Release candidate.
- wip - The current Rhino wip which is +1 of the major release version. For example, if Rhino 8 is currently the release version, wip will be 9.
The workflow using this action should set an env variable with the Rhino Token you create when setting up core-hour billing. Please see this article for instructions on setting up core-hour billing.
This Rhino Token should be stored as a repository secret. For more information on setting up repository secrets, see this article.
# ...
env:
RHINO_TOKEN: ${{ secrets.RHINO_TOKEN }}
jobs:
build:
- name: Install Rhino
uses: mcneel/setup-rhino3d@v2
with:
email-address: ${{ secrets.EMAIL_ADDRESS }}
# ...
Demonstration of using setup-rhino3d in an automated testing scenario. Uses the Rhino.Testing nuget package (see below) to start Rhino and run tests.
Run mcneel/setup-rhino3d@v2
Downloading and installing the latest Rhino 3d...
===> Successfully installed Rhino 8.9.24194.18121
NUnit dotnet unit testing for Rhino3D.
After you've cloned the repository to your local machine or codespace, you'll need to perform some initial setup steps before you can develop your action.
Note
You'll need to have a reasonably modern version of
Node.js handy. If you are using a version manager like
nodenv
or
nvm
, you can run nodenv install
in the
root of your repository to install the version specified in
package.json
. Otherwise, 20.x or later should work!
-
🛠️ Install the dependencies
npm install
-
🏗️ Package the JavaScript for distribution
npm run bundle
[!NOTE]
At the time of writing, this will not copy
script/setup-rhino.ps1
todist/setup-rhino.ps1
. If you change this script, you should move over the changes manually -
✅ Run the tests
$ npm test PASS ./index.test.js ✓ calls run when imported (9 ms) PASS ./main.test.js ✓ sets the input values (84 ms) ✓ fails on Linux (17 ms) ✓ fails on macOS (22 ms) ✓ output script name on Windows (4 ms) ✓ runScript returns
If you have modified any of the js code, do not forget to run npm run bundle
prior to committing changes.
Users expect to consume this action via a version number associated with a tag. Do not forget to add a tag to any commit you wish to use or have users be able to use.