Adding "\n" on code block lines.
This commit is contained in:
parent
8afadeb0dd
commit
a79b36b559
@ -1,5 +1,5 @@
|
|||||||
name: specfileparser
|
name: specfileparser
|
||||||
version: 0.4.3
|
version: 0.4.4
|
||||||
|
|
||||||
authors:
|
authors:
|
||||||
- Philippe Pittoli <karchnu@karchnu.fr>
|
- Philippe Pittoli <karchnu@karchnu.fr>
|
||||||
|
@ -142,7 +142,7 @@ class SpecFileParser
|
|||||||
# puts "code content: #{$~[1]}"
|
# puts "code content: #{$~[1]}"
|
||||||
# old version: str << "#{$~[1].lstrip(" ").rstrip(" ")}"
|
# old version: str << "#{$~[1].lstrip(" ").rstrip(" ")}"
|
||||||
# new version does not change the line (better shell integration)
|
# new version does not change the line (better shell integration)
|
||||||
str << $~[1]
|
str << "#{$~[1]}\n"
|
||||||
else
|
else
|
||||||
content.unshift line
|
content.unshift line
|
||||||
break
|
break
|
||||||
@ -196,7 +196,7 @@ class SpecFileParser
|
|||||||
# puts "blank line or comment, still in a free text in a section"
|
# puts "blank line or comment, still in a free text in a section"
|
||||||
when /#{indent}[ \t]+(.*)/
|
when /#{indent}[ \t]+(.*)/
|
||||||
# puts "code content in section: #{$~[1]}"
|
# puts "code content in section: #{$~[1]}"
|
||||||
str << $~[1]
|
str << "#{$~[1]}\n"
|
||||||
else
|
else
|
||||||
content.unshift line
|
content.unshift line
|
||||||
break
|
break
|
||||||
|
Reference in New Issue
Block a user