mirror of https://github.com/actions/setup-node
Compare commits
3 Commits
eaee1896a4
...
fa465f7fc2
Author | SHA1 | Date |
---|---|---|
Thang Le | fa465f7fc2 | |
William Entriken | 0a44ba7841 | |
thangle | c1b361d808 |
|
@ -21,7 +21,7 @@ See [action.yml](action.yml)
|
||||||
- uses: actions/setup-node@v4
|
- uses: actions/setup-node@v4
|
||||||
with:
|
with:
|
||||||
# Version Spec of the version to use in SemVer notation.
|
# Version Spec of the version to use in SemVer notation.
|
||||||
# It also admits such aliases as lts, latest, nightly and canary builds
|
# It also admits such aliases as lts/*, latest, nightly and canary builds
|
||||||
# Examples: 12.x, 10.15.1, >=10.15.0, lts/Hydrogen, 16-nightly, latest, node
|
# Examples: 12.x, 10.15.1, >=10.15.0, lts/Hydrogen, 16-nightly, latest, node
|
||||||
node-version: ''
|
node-version: ''
|
||||||
|
|
||||||
|
|
|
@ -94426,6 +94426,7 @@ const util_1 = __nccwpck_require__(2629);
|
||||||
const constants_1 = __nccwpck_require__(9042);
|
const constants_1 = __nccwpck_require__(9042);
|
||||||
function run() {
|
function run() {
|
||||||
return __awaiter(this, void 0, void 0, function* () {
|
return __awaiter(this, void 0, void 0, function* () {
|
||||||
|
var _a;
|
||||||
try {
|
try {
|
||||||
//
|
//
|
||||||
// Version is optional. If supplied, install / use from the tool cache
|
// Version is optional. If supplied, install / use from the tool cache
|
||||||
|
@ -94442,6 +94443,10 @@ function run() {
|
||||||
if (!arch) {
|
if (!arch) {
|
||||||
arch = os_1.default.arch();
|
arch = os_1.default.arch();
|
||||||
}
|
}
|
||||||
|
if ((_a = process.env.AGENT_TOOLSDIRECTORY) === null || _a === void 0 ? void 0 : _a.trim()) {
|
||||||
|
process.env['RUNNER_TOOL_CACHE'] = process.env['AGENT_TOOLSDIRECTORY'];
|
||||||
|
}
|
||||||
|
core.debug(`Node is expected to be installed into ${process.env['RUNNER_TOOL_CACHE']}`);
|
||||||
if (version) {
|
if (version) {
|
||||||
const token = core.getInput('token');
|
const token = core.getInput('token');
|
||||||
const auth = !token ? undefined : `token ${token}`;
|
const auth = !token ? undefined : `token ${token}`;
|
||||||
|
|
|
@ -33,6 +33,14 @@ export async function run() {
|
||||||
arch = os.arch();
|
arch = os.arch();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (process.env.AGENT_TOOLSDIRECTORY?.trim()) {
|
||||||
|
process.env['RUNNER_TOOL_CACHE'] = process.env['AGENT_TOOLSDIRECTORY'];
|
||||||
|
}
|
||||||
|
|
||||||
|
core.debug(
|
||||||
|
`Node is expected to be installed into ${process.env['RUNNER_TOOL_CACHE']}`
|
||||||
|
);
|
||||||
|
|
||||||
if (version) {
|
if (version) {
|
||||||
const token = core.getInput('token');
|
const token = core.getInput('token');
|
||||||
const auth = !token ? undefined : `token ${token}`;
|
const auth = !token ? undefined : `token ${token}`;
|
||||||
|
|
Loading…
Reference in New Issue