Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit25d3be0

Browse files
committed
Restructure project files
1 parent52df12c commit25d3be0

File tree

51 files changed

+2053
-327
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

51 files changed

+2053
-327
lines changed

‎.eslintrc.json‎

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"sourceType":"module",
77
"project":"./tsconfig.json"
88
},
9-
"plugins": ["@typescript-eslint","prettier"],
9+
"plugins": ["@typescript-eslint","prettier","import"],
1010
"extends": [
1111
"eslint:recommended",
1212
"plugin:@typescript-eslint/recommended",
@@ -69,5 +69,10 @@
6969
}
7070
]
7171
},
72-
"ignorePatterns": ["out","dist","**/*.d.ts"]
72+
"ignorePatterns": ["out","dist","**/*.d.ts"],
73+
"settings": {
74+
"import/resolver": {
75+
"typescript": {}
76+
}
77+
}
7378
}

‎.vscode-test.mjs‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import{defineConfig}from"@vscode/test-cli";
22

33
exportdefaultdefineConfig({
4-
files:"out/test/**/*.test.js",
4+
files:"out/test/integration/**/*.test.js",
55
extensionDevelopmentPath:".",
66
extensionTestsPath:"./out/test",
77
launchArgs:["--enable-proposed-api","coder.coder-remote"],

‎.vscodeignore‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,4 +13,4 @@ node_modules/**
1313
**/*.map
1414
**/*.ts
1515
*.gif
16-
fixtures/**
16+
test/**

‎package.json‎

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -330,11 +330,12 @@
330330
"@types/glob":"^7.1.3",
331331
"@types/node":"^22.14.1",
332332
"@types/node-forge":"^1.3.11",
333+
"@types/semver":"^7.7.1",
333334
"@types/ua-parser-js":"0.7.36",
334335
"@types/vscode":"^1.73.0",
335336
"@types/ws":"^8.18.1",
336-
"@typescript-eslint/eslint-plugin":"^7.0.0",
337-
"@typescript-eslint/parser":"^6.21.0",
337+
"@typescript-eslint/eslint-plugin":"^8.44.0",
338+
"@typescript-eslint/parser":"^8.44.0",
338339
"@vitest/coverage-v8":"^3.2.4",
339340
"@vscode/test-cli":"^0.0.11",
340341
"@vscode/test-electron":"^2.5.2",
@@ -344,7 +345,8 @@
344345
"dayjs":"^1.11.13",
345346
"eslint":"^8.57.1",
346347
"eslint-config-prettier":"^9.1.0",
347-
"eslint-plugin-import":"^2.31.0",
348+
"eslint-import-resolver-typescript":"^4.4.4",
349+
"eslint-plugin-import":"^2.32.0",
348350
"eslint-plugin-md":"^1.0.19",
349351
"eslint-plugin-package-json":"^0.40.1",
350352
"eslint-plugin-prettier":"^5.4.1",

‎src/cliUtils.test.ts‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1+
import*asclifrom"@/cliUtils";
12
importfsfrom"fs/promises";
23
importosfrom"os";
34
importpathfrom"path";
45
import{beforeAll,describe,expect,it}from"vitest";
5-
import*asclifrom"./cliUtils";
66

77
describe("cliUtils",()=>{
88
consttmp=path.join(os.tmpdir(),"vscode-coder-tests");

‎src/core/cliManager.test.ts‎

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -8,20 +8,17 @@ import * as os from "os";
88
import*aspathfrom"path";
99
import{afterEach,beforeEach,describe,expect,it,vi}from"vitest";
1010
import*asvscodefrom"vscode";
11-
import{
12-
MockConfigurationProvider,
13-
MockProgressReporter,
14-
MockUserInteraction,
15-
}from"../__mocks__/testHelpers";
16-
import*asclifrom"../cliUtils";
17-
import{Logger}from"../logging/logger";
18-
import*aspgpfrom"../pgp";
19-
import{CliManager}from"./cliManager";
20-
import{PathResolver}from"./pathResolver";
11+
import*asclifrom"@/cliManager";
12+
import{CliManager}from"@/core/cliManager";
13+
import{PathResolver}from"@/core/pathResolver";
14+
import{Logger}from"@/logging/logger";
15+
import*aspgpfrom"@/pgp";
2116

2217
vi.mock("os");
2318
vi.mock("axios");
2419
vi.mock("../pgp");
20+
vi.mock("@/cliManager");
21+
vi.mock("@/pgp");
2522

2623
vi.mock("fs",async()=>{
2724
constmemfs:{fs:typeoffs}=awaitvi.importActual("memfs");

‎src/core/secretsManager.ts‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ export class SecretsManager {
2020
publicasyncgetSessionToken():Promise<string|undefined>{
2121
try{
2222
returnawaitthis.secrets.get("sessionToken");
23-
}catch(ex){
23+
}catch{
2424
// The VS Code session store has become corrupt before, and
2525
// will fail to get the session token...
2626
returnundefined;

‎src/remote.ts‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -281,7 +281,7 @@ export class Remote {
281281
// This is useful for debugging with a custom bin!
282282
binaryPath=path.join(os.tmpdir(),"coder");
283283
awaitfs.stat(binaryPath);
284-
}catch(ex){
284+
}catch{
285285
binaryPath=awaitthis.cliManager.fetchBinary(
286286
workspaceClient,
287287
parts.label,
@@ -442,7 +442,7 @@ export class Remote {
442442
this.pathResolver.getUserSettingsPath(),
443443
"utf8",
444444
);
445-
}catch(ex){
445+
}catch{
446446
// Ignore! It's probably because the file doesn't exist.
447447
}
448448

@@ -932,7 +932,7 @@ export class Remote {
932932
.then((parsed)=>{
933933
try{
934934
updateStatus(parsed);
935-
}catch(ex){
935+
}catch{
936936
// Ignore
937937
}
938938
})

‎src/sshConfig.ts‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ export class SSHConfig {
107107
asyncload(){
108108
try{
109109
this.raw=awaitthis.fileSystem.readFile(this.filePath,"utf-8");
110-
}catch(ex){
110+
}catch{
111111
// Probably just doesn't exist!
112112
this.raw="";
113113
}

‎src/sshSupport.ts‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ export function sshSupportsSetEnv(): boolean {
66
constspawned=childProcess.spawnSync("ssh",["-V"]);
77
// The version string outputs to stderr.
88
returnsshVersionSupportsSetEnv(spawned.stderr.toString().trim());
9-
}catch(error){
9+
}catch{
1010
returnfalse;
1111
}
1212
}

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp