3
0
Fork 0
mirror of https://gitea.com/actions/setup-node.git synced 2024-11-22 10:09:33 +01:00

Switch from "master" to "main" branch (#171)

* Switch from "master" to "main" branch

* Update README.md
This commit is contained in:
Maxim Lobanov 2020-07-20 19:50:59 +03:00 committed by GitHub
parent 1ae8f4b1fd
commit 321b6ccb03
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 4 additions and 3 deletions

View file

@ -22,7 +22,7 @@ steps:
node-version: '12' node-version: '12'
``` ```
It will first check the local cache for a semver match. The hosted images have been updated with the latest of each LTS from v8, v10, v12, and v14. `self-hosted` machines will benefit from the cache as well only downloading once. It will pull LTS versions from [node-versions releases](https://github.com/actions/node-versions/releases) and on miss or failure, it will fall back to the previous behavior of download directly from [node dist](https://nodejs.org/dist/). It will first check the local cache for a semver match. The hosted images have been updated with the latest of each LTS from v8, v10, v12, and v14. `self-hosted` machines will benefit from the cache as well only downloading once. It will pull LTS versions from `main` branch of [node-versions](https://github.com/actions/node-versions/blob/main/versions-manifest.json) repository and on miss or failure, it will fall back to the previous behavior of download directly from [node dist](https://nodejs.org/dist/).
The `node-version` input is optional. If not supplied, node which is in your PATH will be used. However, this action will still register problem matchers and support auth features. So setting up the node environment is still a valid scenario without downloading and caching versions. The `node-version` input is optional. If not supplied, node which is in your PATH will be used. However, this action will still register problem matchers and support auth features. So setting up the node environment is still a valid scenario without downloading and caching versions.

2
dist/index.js vendored
View file

@ -13110,7 +13110,7 @@ exports.getNode = getNode;
function getInfoFromManifest(versionSpec, stable, auth) { function getInfoFromManifest(versionSpec, stable, auth) {
return __awaiter(this, void 0, void 0, function* () { return __awaiter(this, void 0, void 0, function* () {
let info = null; let info = null;
const releases = yield tc.getManifestFromRepo('actions', 'node-versions', auth); const releases = yield tc.getManifestFromRepo('actions', 'node-versions', auth, 'main');
const rel = yield tc.findFromManifest(versionSpec, stable, releases); const rel = yield tc.findFromManifest(versionSpec, stable, releases);
if (rel && rel.files.length > 0) { if (rel && rel.files.length > 0) {
info = {}; info = {};

View file

@ -164,7 +164,8 @@ async function getInfoFromManifest(
const releases = await tc.getManifestFromRepo( const releases = await tc.getManifestFromRepo(
'actions', 'actions',
'node-versions', 'node-versions',
auth auth,
'main'
); );
const rel = await tc.findFromManifest(versionSpec, stable, releases); const rel = await tc.findFromManifest(versionSpec, stable, releases);