1
0
mirror of https://gitlab.com/fdroid/fdroidserver.git synced 2024-10-03 17:50:11 +02:00

lint: fix unlinkified links regex

It was incorrectly matching:

	foo [http://bar

and not matching:

	http://foo (start of line)
This commit is contained in:
Daniel Martí 2015-10-25 00:07:33 +02:00
parent ab667992c7
commit db31eddd7e

View File

@ -97,7 +97,7 @@ regex_checks = {
"Unnecessary trailing space"),
(re.compile(r'.*([^[]|^)\[[^:[\]]+( |\]|$)'),
"Invalid link - use [http://foo.bar Link title] or [http://foo.bar]"),
(re.compile(r'.*[^[]https?://[^ ]+'),
(re.compile(r'(^|.* )https?://[^ ]+'),
"Unlinkified link - use [http://foo.bar Link title] or [http://foo.bar]"),
],
}