update rustup as part of install step

This commit is contained in:
softprops 2019-10-27 01:14:57 -04:00
parent 49a71e44df
commit 29e528e000
2 changed files with 4 additions and 5 deletions

View File

@ -17,11 +17,6 @@ async function run() {
if(version) {
await rustup.install();
if (os.platform() !== 'darwin') {
// update the GitHub managed VM version of rustup
// to leverage newer features like "latest latest compatible nightly"
await exec.exec('rustup', ['self', 'update']);
}
await exec.exec('rustup', ['default', version]);
await exec.exec('rustup', ['update', version]);

View File

@ -14,6 +14,10 @@ export async function install() {
core.debug('rustup is located under: ' + toolPath);
core.addPath(path.join(toolPath, 'bin'));
} else {
// update the GitHub managed VM version of rustup
// to leverage newer features like "latest latest compatible nightly"
await exec.exec('rustup', ['self', 'update']);
}
}