Skip to content

windows-rdl / clang: make file paths with spaces clickable with OSC 8 hyperlinks #4356

@riverar

Description

@riverar

When clang encounters errors, such as missing types, in some cases it emits a file path. This file path is not clickable if the path contains spaces. We can fix that with OSC 8 hyperlinks.

  error: unknown type name 'ACME'
   --> C:\Program Files (x86)\Windows Kits\10\\include\10.0.32000.1\um\acme.h:294:9

Ref: https://gist.github.com/egmontkob/eb114294efbcd5adb1944c9f3cb5feda
Demo (in PowerShell):

Write-Host "`e]8;;https://example.com`e\Click me`e]8;;`e\"

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions