Skip to content

Commit

Permalink
Update Node to v18
Browse files Browse the repository at this point in the history
  • Loading branch information
code-asher committed Sep 20, 2023
1 parent 6b83057 commit 9258d92
Show file tree
Hide file tree
Showing 12 changed files with 39 additions and 39 deletions.
24 changes: 12 additions & 12 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,11 +50,11 @@ jobs:
files: |
docs/**
- name: Install Node.js v16
- name: Install Node.js v18
if: steps.changed-files.outputs.any_changed == 'true'
uses: actions/setup-node@v3
with:
node-version: "16"
node-version: "18"
cache: "yarn"

- name: Install doctoc
Expand Down Expand Up @@ -115,11 +115,11 @@ jobs:
files_ignore: |
lib/vscode/**
- name: Install Node.js v16
- name: Install Node.js v18
if: steps.changed-files.outputs.any_changed == 'true'
uses: actions/setup-node@v3
with:
node-version: "16"
node-version: "18"

- name: Fetch dependencies from cache
if: steps.changed-files.outputs.any_changed == 'true'
Expand Down Expand Up @@ -170,11 +170,11 @@ jobs:
files_ignore: |
lib/vscode/**
- name: Install Node.js v16
- name: Install Node.js v18
if: steps.changed-files.outputs.any_changed == 'true'
uses: actions/setup-node@v3
with:
node-version: "16"
node-version: "18"

- name: Fetch dependencies from cache
if: steps.changed-files.outputs.any_changed == 'true'
Expand Down Expand Up @@ -224,10 +224,10 @@ jobs:
- name: Patch Code
run: quilt push -a

- name: Install Node.js v16
- name: Install Node.js v18
uses: actions/setup-node@v3
with:
node-version: "16"
node-version: "18"

- name: Fetch dependencies from cache
id: cache-node-modules
Expand Down Expand Up @@ -298,10 +298,10 @@ jobs:
- name: Install system dependencies
run: sudo apt update && sudo apt install -y libkrb5-dev

- name: Install Node.js v16
- name: Install Node.js v18
uses: actions/setup-node@v3
with:
node-version: "16"
node-version: "18"

- name: Fetch dependencies from cache
id: cache-node-modules
Expand Down Expand Up @@ -357,10 +357,10 @@ jobs:
- name: Install system dependencies
run: sudo apt update && sudo apt install -y libkrb5-dev

- name: Install Node.js v16
- name: Install Node.js v18
uses: actions/setup-node@v3
with:
node-version: "16"
node-version: "18"

- name: Fetch dependencies from cache
id: cache-node-modules
Expand Down
14 changes: 7 additions & 7 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,10 @@ jobs:
- name: Checkout repo
uses: actions/checkout@v3

- name: Install Node.js v16
- name: Install Node.js v18
uses: actions/setup-node@v3
with:
node-version: "16"
node-version: "18"

- name: Install development tools
run: |
Expand Down Expand Up @@ -142,16 +142,16 @@ jobs:
CXX: ${{ format('{0}-g++', matrix.prefix) }}
LINK: ${{ format('{0}-g++', matrix.prefix) }}
NPM_CONFIG_ARCH: ${{ matrix.arch }}
NODE_VERSION: v16.13.0
NODE_VERSION: v18.15.0

steps:
- name: Checkout repo
uses: actions/checkout@v3

- name: Install Node.js v16
- name: Install Node.js v18
uses: actions/setup-node@v3
with:
node-version: "16"
node-version: "18"

- name: Install nfpm
run: |
Expand Down Expand Up @@ -210,10 +210,10 @@ jobs:
- name: Checkout repo
uses: actions/checkout@v3

- name: Install Node.js v16
- name: Install Node.js v18
uses: actions/setup-node@v3
with:
node-version: "16"
node-version: "18"

- name: Install nfpm
run: |
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/security.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,10 @@ jobs:
with:
fetch-depth: 0

- name: Install Node.js v16
- name: Install Node.js v18
uses: actions/setup-node@v3
with:
node-version: "16"
node-version: "18"

- name: Fetch dependencies from cache
id: cache-yarn
Expand Down
4 changes: 2 additions & 2 deletions ci/build/npm-postinstall.sh
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,8 @@ main() {
echo "USE AT YOUR OWN RISK!"
fi

if [ "$major_node_version" -ne "${FORCE_NODE_VERSION:-16}" ]; then
echo "ERROR: code-server currently requires node v16."
if [ "$major_node_version" -ne "${FORCE_NODE_VERSION:-18}" ]; then
echo "ERROR: code-server currently requires node v18."
if [ -n "$FORCE_NODE_VERSION" ]; then
echo "However, you have overrided the version check to use v$FORCE_NODE_VERSION."
fi
Expand Down
2 changes: 1 addition & 1 deletion docs/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ for [VS
Code](https://github.com/Microsoft/vscode/wiki/How-to-Contribute#prerequisites).
Here is what is needed:

- `node` v16.x
- `node` v18.x
- `git` v2.x or greater
- [`git-lfs`](https://git-lfs.github.com)
- [`yarn`](https://classic.yarnpkg.com/en/)
Expand Down
6 changes: 3 additions & 3 deletions docs/android.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@ curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.0/install.sh | bash
```

6. Exit the terminal using `exit` and then reopen the terminal
7. Install and use Node.js 16:
7. Install and use Node.js 18:

```shell
nvm install 16
nvm use 16
nvm install 18
nvm use 18
```

8. Install code-server globally on device with: `npm install --global code-server --unsafe-perm`
Expand Down
4 changes: 2 additions & 2 deletions docs/npm.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ includes installing instructions based on your operating system.
## Node.js version

We use the same major version of Node.js shipped with Code's remote, which is
currently `16.x`. VS Code also [lists Node.js
currently `18.x`. VS Code also [lists Node.js
requirements](https://github.com/microsoft/vscode/wiki/How-to-Contribute#prerequisites).

Using other versions of Node.js [may lead to unexpected
Expand Down Expand Up @@ -79,7 +79,7 @@ Proceed to [installing](#installing)
## FreeBSD

```sh
pkg install -y git python npm-node16 pkgconf
pkg install -y git python npm-node18 pkgconf
pkg install -y libinotify
```

Expand Down
2 changes: 1 addition & 1 deletion docs/termux.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ npm config set python python3
node -v
```

you will get node version `v16.15.0`
you will get Node version `v18`

5. Now install code-server following our guide on [installing with npm](./npm.md)

Expand Down
2 changes: 1 addition & 1 deletion flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
flake-utils.lib.eachDefaultSystem
(system:
let pkgs = nixpkgs.legacyPackages.${system};
nodejs = pkgs.nodejs-16_x;
nodejs = pkgs.nodejs-18_x;
yarn' = pkgs.yarn.override { inherit nodejs; };
in {
devShells.default = pkgs.mkShell {
Expand Down
2 changes: 1 addition & 1 deletion install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -441,7 +441,7 @@ install_npm() {
return
fi
echoerr "Please install npm to install code-server!"
echoerr "You will need at least node v12 and a few C dependencies."
echoerr "You will need at least node v18 and a few C dependencies."
echoerr "See the docs https://coder.com/docs/code-server/latest/install#npm"

exit 1
Expand Down
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
"@types/express": "^4.17.8",
"@types/http-proxy": "^1.17.4",
"@types/js-yaml": "^4.0.0",
"@types/node": "^16.0.0",
"@types/node": "^18.0.0",
"@types/pem": "^1.9.5",
"@types/proxy-from-env": "^1.0.1",
"@types/safe-compare": "^1.1.0",
Expand Down Expand Up @@ -82,7 +82,7 @@
"nanoid": "^3.1.31",
"minimist": "npm:[email protected]",
"glob-parent": "^6.0.1",
"@types/node": "^16.0.0",
"@types/node": "^18.0.0",
"qs": "^6.7.3"
},
"dependencies": {
Expand Down Expand Up @@ -120,7 +120,7 @@
"remote-development"
],
"engines": {
"node": "16"
"node": "18"
},
"jest": {
"transform": {
Expand Down
8 changes: 4 additions & 4 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -285,10 +285,10 @@
resolved "https://registry.yarnpkg.com/@types/mime/-/mime-1.3.2.tgz#93e25bf9ee75fe0fd80b594bc4feb0e862111b5a"
integrity sha512-YATxVxgRqNH6nHEIsvg6k2Boc1JHI9ZbH5iWFFv/MTkchz3b1ieGDa5T0a9RznNdI0KhVbdbWSN+KWWrQZRxTw==

"@types/node@*", "@types/node@^16.0.0":
version "16.18.18"
resolved "https://registry.yarnpkg.com/@types/node/-/node-16.18.18.tgz#06cb0eeb5a0175d26d99b7acf4db613ca30cb07f"
integrity sha512-fwGw1uvQAzabxL1pyoknPlJIF2t7+K90uTqynleKRx24n3lYcxWa3+KByLhgkF8GEAK2c7hC8Ki0RkNM5H15jQ==
"@types/node@*", "@types/node@^18.0.0":
version "18.17.18"
resolved "https://registry.yarnpkg.com/@types/node/-/node-18.17.18.tgz#acae19ad9011a2ab3d792232501c95085ba1838f"
integrity sha512-/4QOuy3ZpV7Ya1GTRz5CYSz3DgkKpyUptXuQ5PPce7uuyJAOR7r9FhkmxJfvcNUXyklbC63a+YvB3jxy7s9ngw==

"@types/pem@^1.9.5":
version "1.9.6"
Expand Down

0 comments on commit 9258d92

Please sign in to comment.