Skip to content

Commit 01e8a61

Browse files
committed
Apply formatting for Imports
1 parent 6953fda commit 01e8a61

91 files changed

Lines changed: 519 additions & 520 deletions

File tree

Some content is hidden

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

.oxfmtrc.json

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,6 @@
22
"$schema": "./node_modules/oxfmt/configuration_schema.json",
33
"printWidth": 120,
44
"semi": false,
5-
"arrowParens": "avoid",
6-
"bracketSpacing": false,
75
"ignorePatterns": ["dist", "out", "coverage", "node_modules", "pnpm-lock.yaml", "pnpm-workspace.yaml"],
86
"experimentalSortImports": {}
97
}

.vscode/settings.json

Lines changed: 6 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,14 @@
11
{
2-
"[typescript]": {
3-
"editor.defaultFormatter": "esbenp.prettier-vscode",
2+
"editor.defaultFormatter": "oxc.oxc-vscode",
3+
"[typescript][javascript][json][yaml]": {
4+
"editor.defaultFormatter": "oxc.oxc-vscode",
45
"editor.formatOnPaste": true,
56
"editor.formatOnSave": true,
67
"editor.formatOnSaveMode": "modificationsIfAvailable",
78
"editor.codeActionsOnSave": {
8-
"source.fixAll.eslint": "explicit",
9-
"source.fixAll.ts": "explicit",
10-
"source.organizeImports.ts": "explicit",
11-
"source.addMissingImports.ts": "explicit"
9+
"source.fixAll.oxc": "explicit"
1210
}
1311
},
14-
"debug.javascript.autoAttachSmartPattern": [
15-
"!esbuild.mjs", //Dont debug our build script automatically, it's annoying
16-
"${workspaceFolder}/**",
17-
"!**/node_modules/**",
18-
"**/$KNOWN_TOOLS$/**"
19-
],
20-
"chat.tools.terminal.autoApprove": {
21-
"/^pnpx madge --circular --extensions ts,tsx \\./src$/": {
22-
"approve": true,
23-
"matchCommandLine": true
24-
}
25-
}
12+
"debug.javascript.autoAttachSmartPattern": ["${workspaceFolder}/**", "!**/node_modules/**", "**/$KNOWN_TOOLS$/**"],
13+
"oxc.enable": true
2614
}

oxlint.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import {defineConfig} from "oxlint"
1+
import { defineConfig } from "oxlint"
22

33
export default defineConfig({
44
categories: {

rolldown.config.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import process from "node:process"
22

3-
import {defineConfig, RolldownOptions} from "rolldown"
3+
import { defineConfig, RolldownOptions } from "rolldown"
44

55
const production = process.env.PRODUCTION === "true"
66

@@ -20,7 +20,7 @@ export default defineConfig([
2020
input: "src/extension.ts",
2121
platform: "node",
2222
transform: {
23-
define: {PRODUCTION: String(production)},
23+
define: { PRODUCTION: String(production) },
2424
},
2525
},
2626
{

script/workspace/vscode-github-actions.code-workspace

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
{
22
"folders": [
3-
{"path": "./languageservices/expressions"},
4-
{"path": "./languageservices/workflow-parser"},
5-
{"path": "./languageservices/languageservice"},
6-
{"path": "./languageservices/languageserver"},
7-
{"path": "./vscode-github-actions"},
3+
{ "path": "./languageservices/expressions" },
4+
{ "path": "./languageservices/workflow-parser" },
5+
{ "path": "./languageservices/languageservice" },
6+
{ "path": "./languageservices/languageserver" },
7+
{ "path": "./vscode-github-actions" },
88
],
99
"extensions": {
1010
"recommendations": ["firsttris.vscode-jest-runner", "Orta.vscode-jest"],

src/api/api.ts

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
1-
import {retry} from "@octokit/plugin-retry"
2-
import {throttling} from "@octokit/plugin-throttling"
3-
import {Octokit} from "@octokit/rest"
1+
import { retry } from "@octokit/plugin-retry"
2+
import { throttling } from "@octokit/plugin-throttling"
3+
import { Octokit } from "@octokit/rest"
44

5-
import {version} from "../../package.json"
6-
import {getGitHubApiUri} from "../configuration/configReader"
7-
import {createOctokitLogger} from "../log"
8-
import {conditionalRequest} from "./conditionalRequests"
5+
import { conditionalRequest } from "~/api/conditionalRequests"
6+
import { getGitHubApiUri } from "~/configuration/configReader"
7+
import { createOctokitLogger } from "~/log"
8+
9+
import { version } from "package.json"
910

1011
export const userAgent = `VS Code GitHub Actions (${version})`
1112

src/api/canReachGitHubAPI.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
import {TTLCache} from "@actions/languageserver/utils/cache"
1+
import { TTLCache } from "@actions/languageserver/utils/cache"
22

3-
import {getSession} from "../auth/auth"
4-
import {logError} from "../log"
5-
import {getClient} from "./api"
3+
import { getClient } from "~/api/api"
4+
import { getSession } from "~/auth/auth"
5+
import { logError } from "~/log"
66

77
const API_ACCESS_TTL_MS = 10 * 1000
88
const cache = new TTLCache(API_ACCESS_TTL_MS)

src/api/conditionalRequests.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
import {assertRequestError} from "../error"
2-
import {logDebug, logError, logTrace} from "../log"
1+
import { assertRequestError } from "~/error"
2+
import { logError, logTrace } from "~/log"
33

44
export const conditionalRequest = () => ({
55
conditionalRequest: returnIfChanged,
@@ -36,9 +36,9 @@ async function returnIfChanged<TResponse, TParams>(
3636
timestamp: boolean = false,
3737
): Promise<TResponse | undefined> {
3838
try {
39-
const options = {...requestParams} as TParams extends {headers: Record<string, string>}
39+
const options = { ...requestParams } as TParams extends { headers: Record<string, string> }
4040
? TParams
41-
: TParams & {headers: Record<string, string>}
41+
: TParams & { headers: Record<string, string> }
4242

4343
const cacheKey = cacheId ?? JSON.stringify(options)
4444
logTrace("🐙 Performing conditional request for cache key:", cacheKey)
@@ -82,7 +82,7 @@ async function returnIfChanged<TResponse, TParams>(
8282
}
8383

8484
logError(err)
85-
throw new Error("Error making conditional request: ", {cause: err})
85+
throw new Error("Error making conditional request: ", { cause: err })
8686
}
8787
}
8888

src/api/handleSamlError.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
import {AuthenticationSession} from "vscode"
1+
import { AuthenticationSession } from "vscode"
22

3-
import {newSession} from "../auth/auth"
4-
import {logDebug} from "../log"
5-
import {getClient, GhaOctokit} from "./api"
3+
import { getClient, GhaOctokit } from "~/api/api"
4+
import { newSession } from "~/auth/auth"
5+
import { logDebug } from "~/log"
66

77
export async function handleSamlError<T>(
88
session: AuthenticationSession,

src/api/rateLimitTelemetry.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
import {Octokit} from "@octokit/core"
2-
import {EventEmitter} from "vscode"
1+
import { Octokit } from "@octokit/core"
2+
import { EventEmitter } from "vscode"
33

44
// Exported variables to track rate limits
55
export interface RateLimit {

0 commit comments

Comments
 (0)