diff --git a/scripts/utils.sh b/scripts/utils.sh index e3e4f53818..85bd8efeb4 100644 --- a/scripts/utils.sh +++ b/scripts/utils.sh @@ -13,7 +13,7 @@ urlfinder(){ # expects ... base_url="$1" content="$(cat "${@:2}")" # read once (could be file descriptors) # explicit links not in markdown - echo "$content" | pcregrep -o '(?{}"'"'"'`]+' + echo "$content" | pcregrep -o '(?{}"'"'"'`]+' # explicit links in markdown echo "$content" | pcregrep -o '(?<=\])\(https?://[^[\]\s]+\)' | pcregrep -o '\((?:[^)(]*(?R)?)*+\)' | pcregrep -o '(?<=\().*(?=\))' # relative links in markdown