Bug 1966892: Add recommended extension and configuration for autolinking bug numbers and phabricator revisions in VSCode terminals. r=Standard8

Differential Revision: https://phabricator.services.mozilla.com/D253154
This commit is contained in:
Dave Townsend
2025-06-11 02:23:48 +00:00
committed by dtownsend@mozilla.com
parent 4da7d4ee45
commit a56f2d9c72
2 changed files with 17 additions and 0 deletions
+2
View File
@@ -20,5 +20,7 @@
"mythmon.idl",
// VSCode Remote Development over SSH
"ms-vscode-remote.remote-ssh",
// Support auto-linking bug numbers and phabricator revisions in the terminal
"fractalbrew.terminal-links",
]
}
@@ -166,6 +166,21 @@ def setup_vscode(command_context, interactive):
"editor.formatOnSave": True,
}
# Add matchers for autolinking bugs and revisions in the terminal.
new_settings = {
**new_settings,
"terminalLinks.matchers": [
{
"regex": "\\b[Bb]ug\\s*(\\d+)\\b",
"uri": "https://bugzilla.mozilla.org/show_bug.cgi?id=$1",
},
{
"regex": "\\b(D\\d+)\\b",
"uri": "https://phabricator.services.mozilla.com/$1",
},
],
}
import difflib
try: