From 2cd558f67f44cca787013c02b665533b97c90f0e Mon Sep 17 00:00:00 2001 From: Ralph Amissah Date: Mon, 3 Sep 2007 21:46:47 +0100 Subject: sisu-0.58 work towards making it possible to describe sisu and sisu markup within sisu --- lib/sisu/v0/dal_syntax.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/sisu/v0/dal_syntax.rb') diff --git a/lib/sisu/v0/dal_syntax.rb b/lib/sisu/v0/dal_syntax.rb index 703d9f1b..292f7343 100644 --- a/lib/sisu/v0/dal_syntax.rb +++ b/lib/sisu/v0/dal_syntax.rb @@ -191,7 +191,7 @@ module Syntax # # #numbered (list) level 1 # _# #numbered (list) level 2 line=line.dup - if line !~/^0~|<:codeline>|<:code-end>/ + unless line =~/^0~|<:codeline>|<:code-end>/ #special characters: ~ { } < > - _ / also used : ^ ! # line_array=[] line.gsub!(/^%{1,4} .+/mi,'') #remove comments @@ -288,7 +288,7 @@ module Syntax else #code blocks line.gsub!(/(^|\s)(https?:\/\/\S+)/,'\1_\2') #line.gsub!(/(^|\s)(http:\/\/\S+)/,"\\1\\\\\\2") #escape urls line.gsub!(/(^|\s)<(https?:\/\/\S+)>([\s,.]|$)/,'\1\2\3') #clean/unescape urls with decoration, re-apply decoration later - line.gsub!(/<:codeline>/,"\n") + line.gsub!(/<:codeline>/,"\n  ") #temporary fix, prefer: #line.gsub!(/<:codeline>/,"\n") end line end -- cgit v1.2.3