Follow the steps outlined in this guide to migrate your project to Rhino 1.12. Before starting, ensure your Git working tree is clean, or back up your project if not using Git.
Rhino 1.12 updates the bundled Node.js dependencies to address security vulnerabilities. As a result, the minimum supported Node.js version is now 20. There were no changes to the application structure.
This guide assumes you are migrating from Rhino 1.10 or 1.11. (Rhino 1.11 did not require a migration guide, as it introduced no changes affecting project structure.) If you are currently using an older version of Rhino, please review the older migration guides first:
- Rhino 1.6 Migration Guide.
- Rhino 1.7 Migration Guide.
- Rhino 1.8 Migration Guide.
- Rhino 1.9 Migration Guide.
- Rhino 1.10 Migration Guide.
Step 1: Ensure Node.js 20 or later
Rhino’s JavaScript and Sass tools now require Node.js 20 or later. Check your version with:
If it is older than 20, install Node.js 20+ from nodejs.org.
If you do not use Rhino’s Node.js-based tools
(build_js(), build_sass(),
lint_js(), lint_sass(),
format_js(), format_sass(),
test_e2e()), this requirement does not apply and you can
skip the .rhino steps below.
Step 2: Install Rhino 1.12
Use the following command to install Rhino 1.12 and update your
renv.lock file:
rhino::pkg_install("rhino@1.12.0")After the installation, restart your R session to ensure all changes take effect.
Step 3: Remove the .rhino directory
The updated Node.js dependencies are picked up only when the
.rhino directory is regenerated. Remove it from the root of
your project:
This directory is recreated automatically and is safe to delete.
Step 4: Regenerate the .rhino directory
Run any Node.js tool to recreate .rhino with the updated
Node modules:
rhino::build_js()Step 5 (optional): Add an AGENTS.md file
Rhino now provides an AGENTS.md file with repository
guidance for AI coding agents. To add it to an existing project,
run:
rhino::use_agents_md()If your project does not already have a GitHub Actions CI workflow
and you would like one, you can now add it to an existing project with
rhino::use_github_actions_ci().
Step 6: Test your project
Test your project thoroughly to ensure everything works properly after the migration. If you encounter any issues or have further questions, don’t hesitate to reach out to us via GitHub Discussions.