VSCode

Editing Vale rules for Ubuntu

This one is strictly related to an issue in Ubuntu documentation. In short I needed to format a very repetitive list of Ubuntu versions and names as Vale rules, going from Ubuntu 24.04 LTS Noble Numbat to - 'Ubuntu 24\.04 LTS \((?!(Noble|Noble Numbat)\))' and (other than escaping the dot in the version number) I'm not too keen on typing my regex patterns into the search box in VSCode.

This helped:

Find:
(\d{2}(?:\sLTS)?\s)(\w+)(\s\w+)

Replace:
$1\((?!($2|$2$3

Last updated