Rename windows-command to batch-command (#6)

This commit is contained in:
Steven Stallion 2025-03-19 22:29:24 -05:00 committed by GitHub
parent e5fb073db2
commit e1efc73f81
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 11 additions and 7 deletions

View file

@ -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

View file

@ -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:

View file

@ -34,6 +34,12 @@ const DEFAULT_SETTINGS: Partial<CommandLineSettings> = {
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<CommandLineSettings> = {
continuationPattern: "\\\\$",
alias: "shell",
},
"windows-command": {
defaultPrompt: "C:\\>",
promptPattern: "^\\S*?>\\s*",
continuationPattern: "\\^$",
alias: "batch",
},
},
};