Skip to content

Exclude box drawing chars from suffix terminal links#320325

Open
KTibow wants to merge 2 commits into
microsoft:mainfrom
KTibow:terminal-suffix-box-drawing-separators
Open

Exclude box drawing chars from suffix terminal links#320325
KTibow wants to merge 2 commits into
microsoft:mainfrom
KTibow:terminal-suffix-box-drawing-separators

Conversation

@KTibow

@KTibow KTibow commented Jun 7, 2026

Copy link
Copy Markdown

When detecting terminal links with line/column suffixes, ASCII pipe is already treated as a path separator so borders like |C:\repo\file.ts:10| link to C:\repo\file.ts instead of including the border.

This applies the same behavior to Unicode box-drawing characters. That keeps suffixed path parsing internally consistent for terminal UIs that draw borders with characters like U+2502, avoiding links such as \u2502C:\repo\file.ts:10 including the border character in the target path.

Changes:

  • Exclude the U+2500-U+257F box-drawing range from suffixed terminal link paths.
  • Extend the existing pipe suffix-link test to cover U+2502.

Validation:

  • git diff --check
  • Direct Node regex validation of ASCII pipe and U+2502 separator behavior

I could not run the browser unit test locally because dependency installation is blocked in this environment: Playwright Chromium does not support ubuntu26.04-arm64, and native-keymap requires the missing system package xkbfile. The commit hook was bypassed after human approval; CI should run the full validation.

Disclosure: This PR was generated by GPT-5.5 with human oversight.

Copilot AI review requested due to automatic review settings June 7, 2026 21:24
@vs-code-engineering

vs-code-engineering Bot commented Jun 7, 2026

Copy link
Copy Markdown
Contributor

📬 CODENOTIFY

The following users are being notified based on files changed in this PR:

@anthonykim1

Matched files:

  • src/vs/workbench/contrib/terminalContrib/links/browser/terminalLinkParsing.ts
  • src/vs/workbench/contrib/terminalContrib/links/test/browser/terminalLinkParsing.test.ts

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Note

Copilot was unable to run its full agentic suite in this review.

Updates terminal link parsing to treat box-drawing characters as link delimiters (in addition to |), and expands tests to cover the new separator behavior.

Changes:

  • Extend the suffix-path parsing regex to exclude Unicode box-drawing characters (\u2500-\u257F) from terminal link paths.
  • Update an existing parsing test to validate behavior for both ASCII pipe (|) and box-drawing vertical bar (\u2502) separators.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.

File Description
src/vs/workbench/contrib/terminalContrib/links/test/browser/terminalLinkParsing.test.ts Extends an existing test to assert link parsing behavior with multiple separator characters.
src/vs/workbench/contrib/terminalContrib/links/browser/terminalLinkParsing.ts Updates the suffix-path regex to stop links at box-drawing characters as well as `

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants