
# Problems: Copy Plus
Copy diagnostic messages from the Problems Panel to the clipboard or a file. This extension provides powerful features to filter, format, and save exactly what you need, overcoming the limitations of VS Code's built-in functionality.
[](https://marketplace.visualstudio.com/items?itemName=Nerkunoff.problems-copy-plus) [](https://open-vsx.org/extension/nerkunoff/problems-copy-plus) [](https://opensource.org/licenses/MIT)
Features
- Copy Everything — Copy diagnostics from all workspace files or just the active file
- Flexible Filtering — Filter by severity, file path patterns (
**/src/*.js), or message content (text or regex like /deprecated/i)
- Custom Formatting — Define output format using template variables (
${message}, ${fileName}, ${startLine}, etc.)
- Multiple Formats — Export as plain text, JSON, or CSV
- CSV Export — Customizable columns, delimiters, and headers for Excel/Google Sheets
- JSON Output — Configurable structure: raw diagnostics, default template, or custom template
- Template Preview — Instant preview of your custom template
- Keybindings — Create shortcuts for specific tasks via
args in keybindings.json
Getting Started
Install the extension from one of these marketplaces:
Or search for Problems: Copy Plus directly in the Extensions panel (Ctrl+Shift+X).
Commands
General Commands
Use from the Command Palette (Ctrl+Shift+P):
| Command |
Description |
Problems: Copy All Problems |
Copy all workspace problems |
Problems: Copy Current File Problems |
Copy problems from active file |
Specialized Commands
Ideal for keybindings; ignore default severity settings:
| Command |
Description |
Problems: Copy All Errors Only |
Copy only errors |
Problems: Copy Current File Errors Only |
Copy errors from active file |
Problems: Copy All Errors and Warnings Only |
Copy errors and warnings |
Problems: Copy Current File Errors and Warnings Only |
Copy errors and warnings from active file |
Problems: Copy All Warnings Only |
Copy only warnings |
Problems: Copy Current File Warnings Only |
Copy warnings from active file |
Problems: Copy All Informations Only |
Copy only info messages |
Problems: Copy Current File Informations Only |
Copy info from active file |
Problems: Copy Open Files Problems |
Copy from open editor tabs only |
Export Commands
Export directly to files (bypass clipboard):
| Command |
Description |
Problems: Export All Problems to CSV |
Export all to CSV |
Problems: Export Current File Problems to CSV |
Export active file to CSV |
Problems: Export All Problems to JSON |
Export all to JSON |
Problems: Export Current File Problems to JSON |
Export active file to JSON |
Settings
General Output
| Setting |
Default |
Description |
problems-copy-plus.format |
text |
Output format: text, json, or csv |
problems-copy-plus.target |
clipboard |
Destination: clipboard or file |
problems-copy-plus.fileLocation |
saveToWorkspaceRoot |
File save location when target is file |
Templates
| Setting |
Description |
problems-copy-plus.templateMode |
default (built-in) or custom (your template) |
problems-copy-plus.customTemplate |
Custom template string with variables |
problems-copy-plus.relatedInfoTemplate |
Format for related information entries |
Available placeholders:
${severity}: Error, Warning, Information, Hint
${path}: Relative path to the file
${fileName}: File name only
${message}: Diagnostic message
${source}: Source (e.g., eslint, ts)
${code}: Error/warning code
${startLine} / ${startCol}: Starting line/column
${endLine} / ${endCol}: Ending line/column
${xdebugLink}: Clickable VS Code link (e.g., vscode://file/C:/path/file.php:42) for quick navigation from Excel
${relatedInfoBlock}: A block of related information (formatted by relatedInfoTemplate).
Severity Filter (in custom template): Specify severity: "Error, Warning" to override global settings.
JSON Options
| Setting |
Default |
Description |
problems-copy-plus.jsonStructure |
raw |
Controls the JSON structure: raw (full diagnostic object), fromDefaultTemplate (JSON from the built-in template), or fromCustomTemplate (JSON from your custom template). Only active when format is json. |
CSV Options
| Setting |
Default |
Description |
problems-copy-plus.csvDelimiter |
, |
Column separator (,, ;, \|, \t) |
problems-copy-plus.csvHeader |
true |
Include header row |
problems-copy-plus.csvColumns |
See below |
Column definitions |
Default CSV columns: Severity, Code, File, Line, Message
Available placeholders for columns: The same as for templates
Filters
| Setting |
Default |
Description |
problems-copy-plus.includeErrors |
true |
Include errors |
problems-copy-plus.includeWarnings |
true |
Include warnings |
problems-copy-plus.includeInformations |
true |
Include information messages |
problems-copy-plus.includeHints |
true |
Include hints |
| Setting |
Default |
Description |
problems-copy-plus.disablePerformanceWarning |
false |
Disable warning for large problem sets (>500) |
Advanced Usage: Keybindings
Create custom shortcuts with unique settings by adding an args section to keybindings.json. Settings in args override global settings for that action.
Example
This keybinding (Alt+C) copies errors and warnings from JS files in src/ containing "deprecated", formatted as JSON:
{
"key": "alt+c",
"command": "problems-copy-plus.copyAll",
"args": {
"errors": true,
"warnings": true,
"informations": false,
"hints": false,
"fileFilter": "**/src/**/*.js",
"messageFilter": "/deprecated/i",
"format": "json"
}
}
Available args
| Parameter |
Values |
Description |
errors, warnings, informations, hints |
true / false |
Include severity levels |
messageFilter |
Text or regex string |
Filter by message content |
fileFilter |
Glob pattern |
Filter by file path |
format |
text, json, csv |
Output format |
target |
clipboard, file |
Output destination |
Default Template Output
${problemNumber}. ${severity}: "${message}"
File: ${path} (${fileName})
Location: [${startLine}:${startCol}]
Source: ${source}(${code})
Code: > ${lineContent}${relatedInfoBlock}
Link: ${xdebugLink}
Example text output
1. Error: "Missing semicolon."
File: path/to/your/file.js (file.js)
Location: [11:5]
Source: eslint(semi)
Code: > const name = 'world'
Link: vscode://file/path/to/your/file.js:11
2. Error: "Cannot redeclare block-scoped variable 'myVar'."
File: path/to/your/file.js (file.js)
Location: [26:7]
Source: typescript(2451)
Code: > const myVar = 42;
Link: vscode://file/path/to/your/file.js:26
- path/to/your/file.js: 'myVar' was also declared here. [6:5]
Example JSON output (raw)
[
{
"resource": "/path/to/your/file.js",
"code": "semi",
"severity": 0,
"message": "Missing semicolon.",
"source": "eslint",
"startLineNumber": 11,
"startColumn": 5,
"endLineNumber": 11,
"endColumn": 16
}
]
Support
If you find this extension useful, consider supporting the project:
Fork
This extension is a fork of Problems: Copy by ArturoDent.