From 5600aee9b22602757d0a675ac53441ac288f0551 Mon Sep 17 00:00:00 2001 From: Andy Waite <13400+andyw8@users.noreply.github.com> Date: Thu, 28 Nov 2024 09:55:40 -0500 Subject: [PATCH] Enable spellcheck for typescript files --- cspell.jsonc | 2 +- project-words | 64 +++++++++++++++++----------- vscode/src/infoCollector.ts | 2 +- vscode/src/rubyLsp.ts | 2 +- vscode/src/status.ts | 4 +- vscode/src/test/suite/common.test.ts | 4 +- vscode/src/test/suite/status.test.ts | 8 ++-- vscode/src/testController.ts | 2 +- 8 files changed, 52 insertions(+), 36 deletions(-) diff --git a/cspell.jsonc b/cspell.jsonc index 341b68e305..d4c98159b1 100644 --- a/cspell.jsonc +++ b/cspell.jsonc @@ -26,7 +26,7 @@ "addon$" // could have false positives but unlikely ], "language": "en", - "files": ["**/*.rb", "**/*.md", "**/*.markdown"], + "files": ["**/*.rb", "**/*.md", "**/*.markdown", "**/*.ts"], "ignorePaths": [ "**/node_modules/**", "vendor/**", diff --git a/project-words b/project-words index ee345cfcd0..34aa174df4 100644 --- a/project-words +++ b/project-words @@ -1,3 +1,29 @@ +Autocorrect +Bizt +Bizw +Corge +Debuggee +EXTGLOB +Eglot +FIXEDENCODING +Floo +Indexables +Ispec +Itest +Jaro +Kaigi +Linearizes +Lstart +Pacman +Shadowenv +Shellwords +Spoom +Supertypes +Vinicius +Winkler +XQRK +YARP +YJIT activestorage autocorrect autoloaded @@ -6,45 +32,34 @@ bigdecimal bindir binmode binread -Bizt -Bizw -bufnr binstub +bufnr bytesize byteslice codepoint codepoints concats copen -Corge +corge +debuggee dont eglot -Eglot eruby -exitstatus -EXTGLOB -FIXEDENCODING -Floo +fakehome fnmatch fooo -gemname hostedtoolcache importmap indexables ipairs -Ispec -Itest ivar -Jaro -Kaigi klass kwargs +libexec linearization -linearizes linearizing lockfiles lspconfig -Lstart metaprogramming mkpath multibyte @@ -52,12 +67,14 @@ nargs nodoc noreturn nvim +onig # abbreviation for oniguruma +pathlist popen +qorge qtlzwssomeking quickfixes -quxx quux -qorge +quxx rdbg readlines realpath @@ -76,20 +93,19 @@ shellwords snode somethi spoom -Spoom streerc stringio strscan subexpression supertypes suppo +truffleruby unaliased unindexed unparser unresolve -Vinicius -Winkler -XQRK +vscodemachineid +vsctm +workdone yarp -YARP -YJIT +yjit diff --git a/vscode/src/infoCollector.ts b/vscode/src/infoCollector.ts index 9efc46006a..566b08f221 100644 --- a/vscode/src/infoCollector.ts +++ b/vscode/src/infoCollector.ts @@ -50,7 +50,7 @@ async function gatherLspInfo( "VS Code Version": vscodeVersion, "Ruby LSP Extension Version": rubyLspExtensionVersion, "Ruby LSP Server Version": rubyLspVersion, - "Ruby LSP Addons": rubyLspAddons, + "Ruby LSP Add-ons": rubyLspAddons, "Ruby Version": workspace.ruby.rubyVersion ?? "Unknown", "Ruby Version Manager": workspace.ruby.versionManager.identifier, "Installed Extensions": extensions.sort(), diff --git a/vscode/src/rubyLsp.ts b/vscode/src/rubyLsp.ts index 6bc84d00e6..f30e615fbd 100644 --- a/vscode/src/rubyLsp.ts +++ b/vscode/src/rubyLsp.ts @@ -462,7 +462,7 @@ export class RubyLsp { return openUris(rubySourceLocation); } - // Old format: we can remove after the Rails addon has been using the new format for a while + // Old format: we can remove after the Rails add-on has been using the new format for a while const [file, line] = rubySourceLocation; const workspace = this.currentActiveWorkspace(); return openFile(this.telemetry, workspace, { diff --git a/vscode/src/status.ts b/vscode/src/status.ts index 665546d7c9..0cf989cc05 100644 --- a/vscode/src/status.ts +++ b/vscode/src/status.ts @@ -172,8 +172,8 @@ export class AddonsStatus extends StatusItem { constructor() { super("addons"); - this.item.name = "Ruby LSP Addons"; - this.item.text = "Fetching addon information"; + this.item.name = "Ruby LSP Add-ons"; + this.item.text = "Fetching add-on information"; } refresh(workspace: WorkspaceInterface): void { diff --git a/vscode/src/test/suite/common.test.ts b/vscode/src/test/suite/common.test.ts index 23f1bc3893..78a695bafa 100644 --- a/vscode/src/test/suite/common.test.ts +++ b/vscode/src/test/suite/common.test.ts @@ -39,8 +39,8 @@ suite("Common", () => { }, } as any); - // For the fake machine of 42 in base 16 and the name `fakeFeature`, the feature flag activation percetange is - // 0.357. For every percetange below that, the feature should appear as disabled + // For the fake machine of 42 in base 16 and the name `fakeFeature`, the feature flag activation percentage is + // 0.357. For every percentage below that, the feature should appear as disabled [0.25, 0.3, 0.35].forEach((percentage) => { (FEATURE_FLAGS as any).fakeFeature = percentage; assert.strictEqual(featureEnabled("fakeFeature" as any), false); diff --git a/vscode/src/test/suite/status.test.ts b/vscode/src/test/suite/status.test.ts index cefb6ed17d..fb16bfac83 100644 --- a/vscode/src/test/suite/status.test.ts +++ b/vscode/src/test/suite/status.test.ts @@ -287,7 +287,7 @@ suite("StatusItems", () => { status.item.text, "Addons: requires server to be v0.17.4 or higher to display this field", ); - assert.strictEqual(status.item.name, "Ruby LSP Addons"); + assert.strictEqual(status.item.name, "Ruby LSP Add-ons"); }); test("Status displays no addons when addons is an empty array", () => { @@ -295,10 +295,10 @@ suite("StatusItems", () => { status.refresh(workspace); assert.strictEqual(status.item.text, "Addons: none"); - assert.strictEqual(status.item.name, "Ruby LSP Addons"); + assert.strictEqual(status.item.name, "Ruby LSP Add-ons"); }); - test("Status displays addon count and command to list commands", () => { + test("Status displays add-on count and command to list commands", () => { workspace.lspClient!.addons = [ { name: "foo", errored: false }, { name: "bar", errored: true }, @@ -307,7 +307,7 @@ suite("StatusItems", () => { status.refresh(workspace); assert.strictEqual(status.item.text, "Addons: 2"); - assert.strictEqual(status.item.name, "Ruby LSP Addons"); + assert.strictEqual(status.item.name, "Ruby LSP Add-ons"); assert.strictEqual(status.item.command?.title, "Details"); assert.strictEqual(status.item.command.command, Command.DisplayAddons); }); diff --git a/vscode/src/testController.ts b/vscode/src/testController.ts index a31a5feb6f..d4c7112eaa 100644 --- a/vscode/src/testController.ts +++ b/vscode/src/testController.ts @@ -121,7 +121,7 @@ export class TestController { // Add nested group to its parent group const group = groupIdMap.get(data.group_id); - // If there's a mistake on the server or in an addon, a code lens may be produced for a non-existing group + // If there's a mistake on the server or in an add-on, a code lens may be produced for a non-existing group if (group) { group.children.add(testItem); } else {