fix: use node 20 instead of node 18

This commit is contained in:
Amin Yahyaabadi 2023-07-15 15:41:58 -07:00
parent a9ef9e1ef4
commit b2cf91c9df
44 changed files with 1126 additions and 1039 deletions

View File

@ -24,7 +24,7 @@ jobs:
- macos-12
- macos-11
node:
- 18
- 20
pnpm:
- 8
steps:
@ -85,7 +85,7 @@ jobs:
node-version: 12
- name: Smoke Test Node 12
run: |
node ./dist/node12/setup-cpp.js --help
node ./dist/legacy/setup-cpp.js --help
- name: Setup Node 16
uses: actions/setup-node@v3
@ -118,11 +118,11 @@ jobs:
./exe/setup-cpp-x64-windows.exe
./exe/setup-cpp-x64-linux
./exe/setup-cpp-x64-macos
./dist/node12/setup-cpp.js
./dist/node12/setup-cpp.js.map
./dist/node12/ # TODO: deprecate node12
./dist/legacy/setup-cpp.js
./dist/legacy/setup-cpp.js.map
./dist/legacy/
./dist/node16/
./dist/node18/
./dist/node20/
Docker:
if: ${{ !contains(github.event.head_commit.message, '[skip ci]') && !contains(github.event.head_commit.message, '[skip test]') }}
@ -133,7 +133,7 @@ jobs:
os:
- ubuntu-22.04
node:
- 18
- 20
pnpm:
- 8
container:

View File

@ -7,7 +7,7 @@ RUN pacman -Syuu --noconfirm && \
pacman -S --noconfirm --needed nodejs
# add setup-cpp.js (built outside of this dockerfile)
COPY "./dist/node18" "/"
COPY "./dist/legacy" "/"
# run installation
RUN node /setup-cpp.js --compiler llvm --cmake true --ninja true --cppcheck true --ccache true --vcpkg true --doxygen true --gcovr true --task true

View File

@ -6,7 +6,7 @@ RUN dnf -y install nodejs npm && \
npm install -g setup-cpp
# add setup-cpp.js (built outside of this dockerfile)
COPY "./dist/node18" "/"
COPY "./dist/legacy" "/"
# run installation
RUN node /setup-cpp.js --compiler llvm --cmake true --ninja true --cppcheck true --ccache true --vcpkg true --doxygen true --gcovr true --task true --powershell true

View File

@ -6,7 +6,7 @@ RUN apt-get update -qq && \
apt-get install -y --no-install-recommends nodejs
# add setup-cpp.js (built outside of this dockerfile)
COPY "./dist/node18" "/"
COPY "./dist/legacy" "/"
# install setup-cpp
RUN node /setup-cpp.js --compiler llvm --cmake true --ninja true --ccache true --vcpkg true --task true

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

42
dist/actions/setup-cpp.js vendored Normal file

File diff suppressed because one or more lines are too long

1
dist/actions/setup-cpp.js.map vendored Normal file

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

42
dist/legacy/setup-cpp.js vendored Normal file

File diff suppressed because one or more lines are too long

1
dist/legacy/setup-cpp.js.map vendored Normal file

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

42
dist/modern/setup-cpp.js vendored Normal file

File diff suppressed because one or more lines are too long

1
dist/modern/setup-cpp.js.map vendored Normal file

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -6,14 +6,15 @@
"license": "Apache-2.0",
"author": "Amin Yahyaabadi",
"exports": {
"import": "./dist/node18/setup-cpp.mjs",
"require": "./dist/node12/setup-cpp.js"
"import": "./dist/modern/setup-cpp.mjs",
"require": "./dist/legacy/setup-cpp.js"
},
"main": "dist/node12/setup-cpp.js",
"main.actions": "./dist/node16/setup-cpp.js",
"main": "dist/legacy/setup-cpp.js",
"actions": "./dist/actions/setup-cpp.js",
"modern": "./dist/modern/setup-cpp.js",
"source": "./src/main.ts",
"bin": {
"setup-cpp": "dist/node12/setup-cpp.js"
"setup-cpp": "dist/legacy/setup-cpp.js"
},
"files": [
"action.yml",
@ -31,7 +32,7 @@
"tsconfig.json"
],
"scripts": {
"build": "shx rm -rf dist/ && shx mkdir -p ./dist/node12 ./dist/node16 ./dist/node18 && run-p lint.tsc build.parcel copy.matchers",
"build": "shx rm -rf dist/ && shx mkdir -p ./dist/legacy ./dist/actions ./dist/modern && run-p lint.tsc build.parcel copy.matchers",
"build.docker": "pnpm build && docker build -f ./dev/docker/ubuntu_node.dockerfile -t setup-cpp .",
"build.docker.arch": "pnpm build && docker build -f ./dev/docker/arch_node.dockerfile -t setup-cpp:arch .",
"build.docker.fedora": "pnpm build && docker build -f ./dev/docker/fedora_node.dockerfile -t setup-cpp:fedora .",
@ -39,10 +40,10 @@
"build.parcel": "cross-env NODE_ENV=production parcel build && babel ./dist --out-dir dist --plugins @upleveled/babel-plugin-remove-node-prefix --compact --no-babelrc --source-maps true",
"bump": "ncu -u -x numerous && pnpm update",
"clean": "shx rm -rf .parcel-cache dist exe",
"copy.matchers": "run-p copy.matchers.node12 copy.matchers.node16 copy.matchers.node18",
"copy.matchers.node12": "shx cp ./src/gcc/gcc_matcher.json ./dist/node12/ && shx cp ./src/msvc/msvc_matcher.json ./dist/node12/ && shx cp ./src/python/python_matcher.json ./dist/node12/ && shx cp ./src/llvm/llvm_matcher.json ./dist/node12/",
"copy.matchers.node16": "shx cp ./src/gcc/gcc_matcher.json ./dist/node16/ && shx cp ./src/msvc/msvc_matcher.json ./dist/node16/ && shx cp ./src/python/python_matcher.json ./dist/node16/ && shx cp ./src/llvm/llvm_matcher.json ./dist/node16/",
"copy.matchers.node18": "shx cp ./src/gcc/gcc_matcher.json ./dist/node18/ && shx cp ./src/msvc/msvc_matcher.json ./dist/node18/ && shx cp ./src/python/python_matcher.json ./dist/node18/ && shx cp ./src/llvm/llvm_matcher.json ./dist/node18/",
"copy.matchers": "run-p copy.matchers.legacy copy.matchers.actions copy.matchers.modern",
"copy.matchers.legacy": "shx cp ./src/gcc/gcc_matcher.json ./dist/legacy/ && shx cp ./src/msvc/msvc_matcher.json ./dist/legacy/ && shx cp ./src/python/python_matcher.json ./dist/legacy/ && shx cp ./src/llvm/llvm_matcher.json ./dist/legacy/",
"copy.matchers.actions": "shx cp ./src/gcc/gcc_matcher.json ./dist/actions/ && shx cp ./src/msvc/msvc_matcher.json ./dist/actions/ && shx cp ./src/python/python_matcher.json ./dist/actions/ && shx cp ./src/llvm/llvm_matcher.json ./dist/actions/",
"copy.matchers.modern": "shx cp ./src/gcc/gcc_matcher.json ./dist/modern/ && shx cp ./src/msvc/msvc_matcher.json ./dist/modern/ && shx cp ./src/python/python_matcher.json ./dist/modern/ && shx cp ./src/llvm/llvm_matcher.json ./dist/modern/",
"dev": "cross-env NODE_ENV=development parcel watch",
"docs": "shx rm -rf packages/*/README.md && pnpm -r exec readme --path ../../dev/readme/template.md -y && pnpm -r exec ts-readme",
"format": "run-s lint.prettier",
@ -72,12 +73,12 @@
"@actions/exec": "^1.1.1",
"@actions/io": "^1.1.3",
"@actions/tool-cache": "^2.0.1",
"@babel/cli": "^7.22.5",
"@babel/cli": "^7.22.9",
"@types/cross-spawn": "^6.0.2",
"@types/eslint": "^8.40.2",
"@types/jest": "^29.5.2",
"@types/eslint": "^8.44.0",
"@types/jest": "^29.5.3",
"@types/mri": "^1.1.1",
"@types/node": "^20.3.2",
"@types/node": "^20.4.2",
"@types/npmcli__ci-detect": "^2.0.0",
"@types/prettier": "2.7.3",
"@types/semver": "^7.5.0",
@ -93,20 +94,20 @@
"escape-path-with-spaces": "^1.0.2",
"escape-quotes": "^1.0.2",
"escape-string-regexp": "^5.0.0",
"eslint": "^8.43.0",
"eslint": "^8.45.0",
"eslint-config-atomic": "^1.19.3",
"exec-powershell": "workspace:*",
"execa": "^7.1.1",
"fast-glob": "^3.2.12",
"fast-glob": "^3.3.0",
"find-up": "^6.3.0",
"gen-readme": "^1.6.0",
"is-url-online": "^1.5.0",
"jest": "^29.5.0",
"jest": "^29.6.1",
"micro-memoize": "^4.1.2",
"mri": "^1.2.0",
"msvc-dev-cmd": "github:aminya/msvc-dev-cmd#9f672c1",
"npm-check-updates": "^16.10.13",
"npm-run-all2": "^6.0.5",
"npm-check-updates": "^16.10.15",
"npm-run-all2": "^6.0.6",
"numerous": "1.0.3",
"parcel": "2.9.3",
"path-exists": "^5.0.0",
@ -121,10 +122,10 @@
"shx": "0.3.4",
"simple-update-notifier": "^2.0.0",
"time-delta": "github:aminya/time-delta#69d91a41cef28e569be9a2991129f5f7d1f0d00e",
"ts-jest": "^29.1.0",
"ts-jest": "^29.1.1",
"ts-node": "^10.9.1",
"ts-readme": "^1.1.3",
"typescript": "^5.1.5",
"typescript": "^5.1.6",
"ubuntu-version": "^2.0.0",
"untildify-user": "workspace:*",
"user-access": "workspace:*",
@ -162,7 +163,7 @@
}
},
"targets": {
"main.legacy": {
"main": {
"context": "node",
"engines": {
"node": ">=12.x"
@ -173,7 +174,7 @@
"optimize": true,
"outputFormat": "commonjs"
},
"main": {
"actions": {
"context": "node",
"engines": {
"node": ">=16.x"
@ -184,10 +185,10 @@
"optimize": true,
"outputFormat": "commonjs"
},
"main.actions": {
"modern": {
"context": "node",
"engines": {
"node": ">=18.x"
"node": ">=20.x"
},
"includeNodeModules": true,
"optimize": true,

View File

@ -11,7 +11,7 @@
"build": "tsc"
},
"dependencies": {
"@actions/core": "^1.9.1",
"@actions/core": "^1.10.0",
"ci-info": "^3.8.0"
},
"keywords": [

View File

@ -15,7 +15,7 @@
"which": "^2.0.2"
},
"devDependencies": {
"@types/which": "^2.0.1"
"@types/which": "^2.0.2"
},
"keywords": [
"powershell",

File diff suppressed because it is too large Load Diff