Support MSbuild row-column format in PathWithPosition (#15589)
This implements #15412. Row-column parsing is changed into a regex to support more complex patterns like the MSBuild diagnostics. Terminal `word_regex` is also relaxed to match those suffixes. Release Notes: - N/A
This commit is contained in:
parent
7a600411cf
commit
06833d7360
2 changed files with 86 additions and 63 deletions
|
@ -427,7 +427,10 @@ impl TerminalBuilder {
|
|||
let _io_thread = event_loop.spawn(); // DANGER
|
||||
|
||||
let url_regex = RegexSearch::new(r#"(ipfs:|ipns:|magnet:|mailto:|gemini://|gopher://|https://|http://|news:|file://|git://|ssh:|ftp://)[^\u{0000}-\u{001F}\u{007F}-\u{009F}<>"\s{-}\^⟨⟩`]+"#).unwrap();
|
||||
let word_regex = RegexSearch::new(r#"[\$\+\w.\[\]:/\\@\-~]+"#).unwrap();
|
||||
// Optional suffix matches MSBuild diagnostic suffixes for path parsing in PathLikeWithPosition
|
||||
// https://learn.microsoft.com/en-us/visualstudio/msbuild/msbuild-diagnostic-format-for-tasks
|
||||
let word_regex =
|
||||
RegexSearch::new(r#"[\$\+\w.\[\]:/\\@\-~]+(?:\((?:\d+|\d+,\d+)\))?"#).unwrap();
|
||||
|
||||
let terminal = Terminal {
|
||||
task,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue