Skip to content

Commit

Permalink
Update Code to 1.90.0 (#6824)
Browse files Browse the repository at this point in the history
Additionally:

- Update Node to 20.11.1
- Update documentation
- Disable extension signature verification

This works around an issue where the Open VSX is not returning the
expected zip.  Verification is skipped later anyway because
@vscode/vsce-sign is missing in the OSS version.
  • Loading branch information
benz0li authored Jun 6, 2024
1 parent fc47b4f commit 6d9530a
Show file tree
Hide file tree
Showing 23 changed files with 82 additions and 69 deletions.
2 changes: 1 addition & 1 deletion .node-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
18.18.2
20.11.1
4 changes: 2 additions & 2 deletions ci/build/npm-postinstall.sh
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,8 @@ main() {
echo "USE AT YOUR OWN RISK!"
fi

if [ "$major_node_version" -ne "${FORCE_NODE_VERSION:-18}" ]; then
echo "ERROR: code-server currently requires node v18."
if [ "$major_node_version" -ne "${FORCE_NODE_VERSION:-20}" ]; then
echo "ERROR: code-server currently requires node v20."
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` v18.x
- `node` v20.x
- `git` v2.x or greater
- [`git-lfs`](https://git-lfs.github.com)
- [`yarn`](https://classic.yarnpkg.com/en/)
Expand Down
2 changes: 1 addition & 1 deletion docs/android.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ 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 18:
7. Install and use Node.js 20:

```shell
nvm install 18
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 `18.x`. VS Code also [lists Node.js
currently `20.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-node18 pkgconf
pkg install -y git python npm-node20 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 @@ -57,7 +57,7 @@ npm config set python python3
node -v
```

you will get Node version `v18`
you will get Node version `v20`

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

Expand Down
17 changes: 8 additions & 9 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

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-18_x;
nodejs = pkgs.nodejs_20;
yarn' = pkgs.yarn.override { inherit nodejs; };
in {
devShells.default = pkgs.mkShell {
Expand Down
2 changes: 1 addition & 1 deletion lib/vscode
Submodule vscode updated 1130 files
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.17",
"@types/http-proxy": "1.17.7",
"@types/js-yaml": "^4.0.6",
"@types/node": "^18.0.0",
"@types/node": "20.x",
"@types/pem": "^1.14.1",
"@types/proxy-from-env": "^1.0.1",
"@types/safe-compare": "^1.1.0",
Expand Down Expand Up @@ -88,7 +88,7 @@
"xdg-basedir": "^4.0.0"
},
"resolutions": {
"@types/node": "^18.0.0"
"@types/node": "20.x"
},
"bin": {
"code-server": "out/node/entry.js"
Expand All @@ -103,7 +103,7 @@
"remote-development"
],
"engines": {
"node": "18"
"node": "20"
},
"jest": {
"transform": {
Expand Down
6 changes: 3 additions & 3 deletions patches/base-path.diff
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Index: code-server/lib/vscode/src/vs/base/common/network.ts
===================================================================
--- code-server.orig/lib/vscode/src/vs/base/common/network.ts
+++ code-server/lib/vscode/src/vs/base/common/network.ts
@@ -205,7 +205,9 @@ class RemoteAuthoritiesImpl {
@@ -212,7 +212,9 @@ class RemoteAuthoritiesImpl {
return URI.from({
scheme: platform.isWeb ? this._preferredWebSchema : Schemas.vscodeRemoteResource,
authority: `${host}:${port}`,
Expand Down Expand Up @@ -140,11 +140,11 @@ Index: code-server/lib/vscode/src/vs/server/node/webClientServer.ts
+ const base = relativeRoot(getOriginalUrl(req))
+ const vscodeBase = relativePath(getOriginalUrl(req))
+
const productConfiguration = <Partial<IProductConfiguration>>{
const productConfiguration = {
codeServerVersion: this._productService.codeServerVersion,
+ rootEndpoint: base,
embedderIdentifier: 'server-distro',
extensionsGallery: this._webExtensionResourceUrlTemplate ? {
extensionsGallery: this._webExtensionResourceUrlTemplate && this._productService.extensionsGallery ? {
...this._productService.extensionsGallery,
@@ -343,8 +346,10 @@ export class WebClientServer {
const values: { [key: string]: string } = {
Expand Down
2 changes: 1 addition & 1 deletion patches/disable-builtin-ext-update.diff
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ Index: code-server/lib/vscode/src/vs/workbench/contrib/extensions/browser/extens
===================================================================
--- code-server.orig/lib/vscode/src/vs/workbench/contrib/extensions/browser/extensionsWorkbenchService.ts
+++ code-server/lib/vscode/src/vs/workbench/contrib/extensions/browser/extensionsWorkbenchService.ts
@@ -284,6 +284,10 @@ export class Extension implements IExten
@@ -285,6 +285,10 @@ export class Extension implements IExten
if (this.type === ExtensionType.System && this.productService.quality === 'stable') {
return false;
}
Expand Down
14 changes: 7 additions & 7 deletions patches/display-language.diff
Original file line number Diff line number Diff line change
Expand Up @@ -23,14 +23,14 @@ Index: code-server/lib/vscode/src/vs/server/node/serverServices.ts
+++ code-server/lib/vscode/src/vs/server/node/serverServices.ts
@@ -11,7 +11,7 @@ import * as path from 'vs/base/common/pa
import { IURITransformer } from 'vs/base/common/uriIpc';
import { getMachineId, getSqmMachineId } from 'vs/base/node/id';
import { getMachineId, getSqmMachineId, getdevDeviceId } from 'vs/base/node/id';
import { Promises } from 'vs/base/node/pfs';
-import { ClientConnectionEvent, IMessagePassingProtocol, IPCServer, StaticRouter } from 'vs/base/parts/ipc/common/ipc';
+import { ClientConnectionEvent, IMessagePassingProtocol, IPCServer, ProxyChannel, StaticRouter } from 'vs/base/parts/ipc/common/ipc';
import { ProtocolConstants } from 'vs/base/parts/ipc/common/ipc.net';
import { IConfigurationService } from 'vs/platform/configuration/common/configuration';
import { ConfigurationService } from 'vs/platform/configuration/common/configurationService';
@@ -237,6 +237,9 @@ export async function setupServerService
@@ -238,6 +238,9 @@ export async function setupServerService
const channel = new ExtensionManagementChannel(extensionManagementService, (ctx: RemoteAgentConnectionContext) => getUriTransformer(ctx.remoteAuthority));
socketServer.registerChannel('extensions', channel);

Expand Down Expand Up @@ -348,7 +348,7 @@ Index: code-server/lib/vscode/src/vs/workbench/contrib/extensions/browser/extens
===================================================================
--- code-server.orig/lib/vscode/src/vs/workbench/contrib/extensions/browser/extensionsActions.ts
+++ code-server/lib/vscode/src/vs/workbench/contrib/extensions/browser/extensionsActions.ts
@@ -342,9 +342,6 @@ export class InstallAction extends Exten
@@ -341,9 +341,6 @@ export class InstallAction extends Exten
if (this.extension.isBuiltin) {
return;
}
Expand All @@ -358,7 +358,7 @@ Index: code-server/lib/vscode/src/vs/workbench/contrib/extensions/browser/extens
if (this.extension.state === ExtensionState.Uninstalled && await this.extensionsWorkbenchService.canInstall(this.extension)) {
this.enabled = this.options.installPreReleaseVersion ? this.extension.hasPreReleaseVersion : this.extension.hasReleaseVersion;
this.updateLabel();
@@ -615,7 +612,7 @@ export abstract class InstallInOtherServ
@@ -614,7 +611,7 @@ export abstract class InstallInOtherServ
}

if (isLanguagePackExtension(this.extension.local.manifest)) {
Expand All @@ -367,7 +367,7 @@ Index: code-server/lib/vscode/src/vs/workbench/contrib/extensions/browser/extens
}

// Prefers to run on UI
@@ -1843,17 +1840,6 @@ export class SetLanguageAction extends E
@@ -1848,17 +1845,6 @@ export class SetLanguageAction extends E
update(): void {
this.enabled = false;
this.class = SetLanguageAction.DisabledClass;
Expand All @@ -385,15 +385,15 @@ Index: code-server/lib/vscode/src/vs/workbench/contrib/extensions/browser/extens
}

override async run(): Promise<any> {
@@ -1870,7 +1856,6 @@ export class ClearLanguageAction extends
@@ -1875,7 +1861,6 @@ export class ClearLanguageAction extends
private static readonly DisabledClass = `${ClearLanguageAction.EnabledClass} disabled`;

constructor(
- @IExtensionsWorkbenchService private readonly extensionsWorkbenchService: IExtensionsWorkbenchService,
@ILocaleService private readonly localeService: ILocaleService,
) {
super(ClearLanguageAction.ID, ClearLanguageAction.TITLE.value, ClearLanguageAction.DisabledClass, false);
@@ -1880,17 +1865,6 @@ export class ClearLanguageAction extends
@@ -1885,17 +1870,6 @@ export class ClearLanguageAction extends
update(): void {
this.enabled = false;
this.class = ClearLanguageAction.DisabledClass;
Expand Down
Loading

0 comments on commit 6d9530a

Please sign in to comment.