Skip to content

Commit

Permalink
rename
Browse files Browse the repository at this point in the history
  • Loading branch information
AndreasArvidsson committed Jan 29, 2025
1 parent f738b64 commit 0d0981b
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions packages/cursorless-vscode/src/migrateSnippets.ts
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ async function openResultDocument(
const skipMessage =
"Snippets containing `scopeTypes` and/or `excludeDescendantScopeTypes` attributes are not supported by community snippets.";

const contentParts: string[] = [
const content: string[] = [
`# Snippets migrated from Cursorless`,
"",
`From: ${sourceDirectory}`,
Expand All @@ -171,7 +171,7 @@ async function openResultDocument(
];

if (migratedPartiallyKeys.length > 0) {
contentParts.push(
content.push(
`## Migrated ${migratedPartiallyKeys.length} snippet files partially`,
skipMessage,
...migratedPartiallyKeys.map(
Expand All @@ -181,15 +181,15 @@ async function openResultDocument(
}

if (result.skipped.length > 0) {
contentParts.push(
content.push(
`## Skipped ${result.skipped.length} snippet files`,
skipMessage,
...result.skipped.map((key) => `- ${key}`),
);
}

const textDocument = await vscode.workspace.openTextDocument({
content: contentParts.join("\n"),
content: content.join("\n"),
language: "markdown",
});
await vscode.window.showTextDocument(textDocument);
Expand Down

0 comments on commit 0d0981b

Please sign in to comment.