From e1efc73f81a928d88465309390296f4df2f87b43 Mon Sep 17 00:00:00 2001 From: Steven Stallion Date: Wed, 19 Mar 2025 22:29:24 -0500 Subject: [PATCH] Rename windows-command to batch-command (#6) --- CHANGELOG.md | 4 ++++ README.md | 2 +- src/main.ts | 12 ++++++------ 3 files changed, 11 insertions(+), 7 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index ced4e43..79bc497 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +### Changed + +- Renamed `windows-command` to `batch-command` for consistency + ## [1.0.0] - 2025-03-11 Initial release diff --git a/README.md b/README.md index e1b86ea..f9589ca 100644 --- a/README.md +++ b/README.md @@ -23,9 +23,9 @@ Command line code blocks are identified using one of the following languages: | Name | Highlight | Prompt Pattern | Default Prompt | Continuation | | -------------------- | ------------ | -------------- | -------------- | ------------ | +| `batch-command` | `batch` | `/\S*?>/` | `C:\>` | `^` | | `powershell-command` | `powershell` | `/\S*?>/` | `PS>` | `` ` `` | | `shell-command` | `shell` | `/\S*?[#$%]/` | `$` | `\` | -| `windows-command` | `batch` | `/\S*?>/` | `C:\>` | `^` | For example, copying the following code block to the clipboard will remove the prompt and output while preserving line continuations and white space: diff --git a/src/main.ts b/src/main.ts index 1a0443f..5a349b4 100644 --- a/src/main.ts +++ b/src/main.ts @@ -34,6 +34,12 @@ const DEFAULT_SETTINGS: Partial = { highlight: false, normalize: false, languages: { + "batch-command": { + defaultPrompt: "C:\\>", + promptPattern: "^\\S*?>\\s*", + continuationPattern: "\\^$", + alias: "batch", + }, "powershell-command": { defaultPrompt: "PS>", promptPattern: "^\\S*?>\\s*", @@ -46,12 +52,6 @@ const DEFAULT_SETTINGS: Partial = { continuationPattern: "\\\\$", alias: "shell", }, - "windows-command": { - defaultPrompt: "C:\\>", - promptPattern: "^\\S*?>\\s*", - continuationPattern: "\\^$", - alias: "batch", - }, }, };