rig rtools
Windows only
Manage Rtools installations (Windows only).
Rtools is the collection of build tools (compilers, make, etc.) needed to build R packages from source on Windows. Each R version needs a matching Rtools version.
rig rtools list lists the installed Rtools versions. rig rtools add installs Rtools, by default every version needed by the currently installed R versions. rig rtools rm removes Rtools versions.
On non-Windows platforms this command does nothing and is hidden.
Subcommands
rig rtools add
Install new Rtools versions on Windows.
You can specify the new version(s) by their name, optionally with an ‘rtools’ prefix, e.g. ‘43’ or ‘rtools43’.
If version is ‘all’ (the default), then all Rtools versions that are required for the currently installed R versions will be installed.
In user mode (RIG_MODE=user) Rtools is installed per-user, without administrator rights, into %APPDATA%\rig\data\rtools (override with the RIG_RTOOLS_INSTALL_DIR environment variable or the rtools-install-dir config setting). rig points each R version at it by setting RTOOLS<ver>_HOME in that R version’s etc\Renviron.site.
In admin mode this command needs an administrator account.
Usage
rig rtools add [OPTIONS] [version]
Arguments
[version]- Rtools version to add, e.g. ‘43’ [default: all]
Options
--admin- Run in admin mode (overrides RIG_MODE and config)
-a, --arch <arch>- Architecture to install Rtools for (default: native arch). [possible values: x86_64, aarch64, arm64]
-h, --help- Print help (see a summary with ‘-h’)
--user- Run in user mode (overrides RIG_MODE and config)
Examples
rig rtools add 43
rig rtools add allrig rtools list
List installed Rtools versions on Windows.
It only lists versions that are added to the Windows Registry.
Use the --json flag for JSON output.
Usage
rig rtools list [OPTIONS]
Options
--admin- Run in admin mode (overrides RIG_MODE and config)
-h, --help- Print help (see a summary with ‘-h’)
--json- JSON output
--user- Run in user mode (overrides RIG_MODE and config)
rig rtools rm
Remove Rtools versions on Windows.
You can specify the version(s) to remove by their name, optionally with an ‘rtools’ prefix, e.g. ‘43’ or ‘rtools43’.
If no version is specified, then it does nothing.
In admin mode this command needs an administrator account.
Usage
rig rtools rm [OPTIONS] [version]...
Arguments
[version]...- versions to remove
Options
--admin- Run in admin mode (overrides RIG_MODE and config)
-a, --arch <arch>- Architecture of Rtools to remove (default: native arch). [possible values: x86_64, aarch64, arm64]
-h, --help- Print help (see a summary with ‘-h’)
--user- Run in user mode (overrides RIG_MODE and config)
Examples
rig rtools rm 43