Archived
1
0

chore: move to patches (#4997)

* Move integration types into code-server

This will be easier to maintain than to have it as a patch.

* Disable connection token

Using a flag means we will not need to patch it out.  I think this is
new from 1.64?

* Add product.json to build process

This way we do not have to patch it.

* Ship with remote agent package.json

Instead of the root one.  This contains fewer dependencies.

* Let Code handle errors

This way we will not have to patch Code to make this work and I think it
makes sense to let Code handle the request.

If we do want to handle errors we can do it cleanly by patching their
error handler to throw instead.

* Move manifest override into code-server

This way we will not have to patch it.

* Move to patches

- Switch submodule to track upstream
- Add quilt to the process
- Add patches

The node-* ignore was ignoring one of the diffs so I removed it.  This
was added when we were curling Node as node-v{version}-darwin-x64 for
the macOS build but this no longer happens (we use the Node action to
install a specific version now so we just use the system-wide Node).

* Use pre-packaged Code
This commit is contained in:
Asher
2022-03-22 15:07:14 -05:00
committed by GitHub
parent be727871f6
commit a1af9e2a56
37 changed files with 2240 additions and 205 deletions

View File

@ -12,7 +12,7 @@ import {
setDefaults,
shouldOpenInExistingInstance,
splitOnFirstEquals,
toVsCodeArgs,
toCodeArgs,
optionDescriptions,
options,
Options,
@ -727,11 +727,11 @@ describe("readSocketPath", () => {
})
})
describe("toVsCodeArgs", () => {
describe("toCodeArgs", () => {
const vscodeDefaults = {
...defaults,
"connection-token": "0000",
"accept-server-license-terms": true,
compatibility: "1.64",
help: false,
port: "8080",
version: false,
@ -744,7 +744,7 @@ describe("toVsCodeArgs", () => {
})
it("should convert empty args", async () => {
expect(await toVsCodeArgs(await setDefaults(parse([])))).toStrictEqual({
expect(await toCodeArgs(await setDefaults(parse([])))).toStrictEqual({
...vscodeDefaults,
})
})
@ -752,7 +752,7 @@ describe("toVsCodeArgs", () => {
it("should ignore regular file", async () => {
const file = path.join(await tmpdir(testName), "file")
await fs.writeFile(file, "foobar")
expect(await toVsCodeArgs(await setDefaults(parse([file])))).toStrictEqual({
expect(await toCodeArgs(await setDefaults(parse([file])))).toStrictEqual({
...vscodeDefaults,
_: [file],
})