1
0
mirror of https://github.com/bitcoin/bips.git synced 2026-07-13 17:56:00 +00:00

script: don't raise on [url](url) in markdown grep

This commit is contained in:
Jon Atack
2026-07-10 11:25:25 -06:00
parent c9aa2437ab
commit 8268d40e58

View File

@@ -24,7 +24,7 @@ done < <(find . -type f -name '*.mediawiki' | sort)
MARKDOWN_ECODE=0 MARKDOWN_ECODE=0
while IFS= read -r fname; do while IFS= read -r fname; do
GRES=$(grep -nE '\[[[:space:]]*https?://[^][]*\]|\[\[(\.\./|/)?bip-[^][]*\]\]' "$fname") GRES=$(grep -nE '\[[[:space:]]*https?://[^][[:space:]]+[[:space:]]+[^][]*\]|\[\[https?://[^][]*\]\]|\[\[(\.\./|/)?bip-[^][]*\]\]' "$fname")
if [ "$GRES" != "" ]; then if [ "$GRES" != "" ]; then
if [ $MARKDOWN_ECODE -eq 0 ]; then if [ $MARKDOWN_ECODE -eq 0 ]; then
>&2 echo "Github Markdown format writes links as [text](URL), not as [URL text] or [[URL|text]]:" >&2 echo "Github Markdown format writes links as [text](URL), not as [URL text] or [[URL|text]]:"