install method

Future<void> install({
  1. bool modifyPath = true,
  2. String? cargoHome,
  3. String? rustupHome,
})

Implementation

Future<void> install({
  bool modifyPath = true,
  String? cargoHome,
  String? rustupHome,
}) async {
  await runCommand(
    _scriptPath(),
    [
      '--default-toolchain',
      'none',
      '-y',
      if (!modifyPath) '--no-modify-path',
    ],
    environment: {
      if (cargoHome != null) 'CARGO_HOME': cargoHome,
      if (rustupHome != null) 'RUSTUP_HOME': rustupHome,
    },
    logger: _logger,
  );
}