From ec1f99bc5a8174d85f26b89a7c86bfa895e35662 Mon Sep 17 00:00:00 2001 From: Petter Reinholdtsen Date: Thu, 22 Feb 2018 22:28:53 +0100 Subject: [PATCH] Adjust fixup.rb to recognize more references. --- fixup.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/fixup.rb b/fixup.rb index 4561ab7..7127318 100644 --- a/fixup.rb +++ b/fixup.rb @@ -258,8 +258,8 @@ data.each_with_index do |lin, idx| scope=$1.gsub(" ", "-") end # First, mark note reference - lin.sub!(/([a-z]\.["”]?)(\d+)(\s)/, "\\1[^" + scope + "-\\2]\\3") - lin.sub!(/([a-z]\.["”]?)(\d+)$/, "\\1[^" + scope + "-\\2]") + lin.sub!(/([a-z][\.\)]+["”]?)(\d+)(\s)/, "\\1[^" + scope + "-\\2]\\3") + lin.sub!(/([a-z][\.\)]+["”]?)(\d+)$/, "\\1[^" + scope + "-\\2]") # Next, mark note content, only between /Web Links?|Notes/ and next heading if noteblock lin.sub!(/^(\d+)\. /, "[^" + scope + "-\\1]: ") -- 2.47.2