aboutsummaryrefslogtreecommitdiffhomepage
path: root/lib
diff options
context:
space:
mode:
authorRalph Amissah <ralph@amissah.com>2019-09-02 11:47:30 -0400
committerRalph Amissah <ralph@amissah.com>2019-09-03 12:28:38 -0400
commit2c80909caf8b6db80d35fcbbdc7936824d76083a (patch)
treeb2cf0d0bc9c73b4c25717bbbc5c37902cbd6dbd6 /lib
parentmarkup modification: code blocks attributes, numberlines (diff)
re-introduce depreciated markup for numbering codeblocks
Diffstat (limited to 'lib')
-rw-r--r--lib/sisu/ao_doc_str.rb5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/sisu/ao_doc_str.rb b/lib/sisu/ao_doc_str.rb
index 1aba9bd7..40f5a045 100644
--- a/lib/sisu/ao_doc_str.rb
+++ b/lib/sisu/ao_doc_str.rb
@@ -515,9 +515,12 @@ module SiSU_AO_DocumentStructureExtract
end
@@counter=1
@codeblock_numbered=
- (t_o =~/^(?:code(?:\.[a-z][0-9a-z_]+)?\(.*number(?:lines)?.*?\)\{|```[ ]+code(?:\.[a-z][0-9a-z_]+)?\(.*number(?:lines)?.*?\))/) \
+ (t_o =~/^(?:code(?:\.[a-z][0-9a-z_]+)?\(.*number(?:lines)?.*?\)\{|```[ ]+code(?:\.[a-z][0-9a-z_]+)?\(.*number(?:lines)?.*?\)|code(?:\.[a-z][0-9a-z_]+)?\{#|```[ ]+code(?:\.[a-z][0-9a-z_]+)?\s[#])/) \
? true
: false
+ if (t_o =~/^(?:code(?:\.[a-z][0-9a-z_]+)?\{#|```[ ]+code(?:\.[a-z][0-9a-z_]+)?\s[#])/)
+ puts "WARNING document using depreciated markup for numbering codeblocks\nuse: code(numberlines){ ... or: ```code(numberlines) ..."
+ end
@num_id[:code_block] +=1
h={
is_for: :code,