Closed Ir1d closed 5 years ago
In mkdocs-material, the links don't have to end with .md, for example: [asdf](/xx/yy) works fine.
.md
[asdf](/xx/yy)
I've tried [^!]\[([^\]]+?)\]\(([^http].*?)\),
[^!]\[([^\]]+?)\]\(([^http].*?)\)
but in here it touches the code blocks. (LGTM now)
I've generated a few test cases:
[asdfasdf](asdasdf) [asdfasdf](asdasdf.md) [asdfasdf](/asdasdf) [asdfasdf](./asdasdf) ![asdfasdf](./images/asdasdf.jpg) [asdfasdf](http://example.com) [asdfasdf](https://example.com) [asdfasdf](file:///example.com) [Testlib](#testlib) [asdfasdf](/asdasdf) asdfasfasdfasdfd [asdfasdf](/asdasdf) asdfasdfasdf[asdfasdf](/asdasdf) int operator[](const int a) { return to[a]; } ![Word Art](/home/asdfasdf/images/wordArt.png)
regex101: https://regex101.com/r/jw7aY4/3
In mkdocs-material, the links don't have to end with
.md
, for example:[asdf](/xx/yy)
works fine.I've tried
[^!]\[([^\]]+?)\]\(([^http].*?)\)
,but in here it touches the code blocks.(LGTM now)I've generated a few test cases:
regex101: https://regex101.com/r/jw7aY4/3