feat(cheddar): Implement highlighting of CL and bug shortlinks
Implements highlighting of shortlinks like cl/123, or b/123. Highlighting works by replacing the input Markdown using a simple regular expression replacement. We also considered parsing and replacing these links in the Markdown AST, but it would have been significantly more complex (due to arena allocation) for little upside and no obvious performance benefit. Change-Id: I53f03fb17491046d89d0b7f605929571c11ee9a8 Reviewed-on: https://cl.tvl.fyi/c/depot/+/3082 Tested-by: BuildkiteCI Reviewed-by: eta <eta@theta.eu.org>
This commit is contained in:
parent
57502cfc46
commit
a9902dadcf
4 changed files with 51 additions and 1 deletions
1
tools/cheddar/Cargo.lock
generated
1
tools/cheddar/Cargo.lock
generated
|
|
@ -196,6 +196,7 @@ dependencies = [
|
|||
"clap",
|
||||
"comrak",
|
||||
"lazy_static",
|
||||
"regex",
|
||||
"rouille",
|
||||
"serde",
|
||||
"serde_json",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue