mirror of
https://github.com/moonrepo/setup-rust.git
synced 2025-04-20 09:38:43 +00:00
Add to PATH.
This commit is contained in:
parent
c3ef13296b
commit
64b109dfe7
2 changed files with 6 additions and 1 deletions
|
@ -1,4 +1,4 @@
|
|||
name: 'Setup Rust'
|
||||
name: 'Setup rustup toolchain'
|
||||
author: 'Miles Johnson'
|
||||
description: 'Sets up Rust and Cargo.'
|
||||
inputs:
|
||||
|
|
5
index.ts
5
index.ts
|
@ -1,4 +1,5 @@
|
|||
import fs from 'fs';
|
||||
import os from 'os';
|
||||
import path from 'path';
|
||||
import * as core from '@actions/core';
|
||||
import * as exec from '@actions/exec';
|
||||
|
@ -135,6 +136,10 @@ async function run() {
|
|||
|
||||
// Always enable colored output
|
||||
core.exportVariable('CARGO_TERM_COLOR', 'always');
|
||||
|
||||
core.info('Adding ~/.cargo/bin to PATH');
|
||||
|
||||
core.addPath(path.join(os.homedir(), '.cargo', 'bin'));
|
||||
}
|
||||
|
||||
void run();
|
||||
|
|
Loading…
Add table
Reference in a new issue