summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xhtml2md.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/html2md.rb b/html2md.rb
index 7b89309..fde907d 100755
--- a/html2md.rb
+++ b/html2md.rb
@@ -53,8 +53,8 @@ end
# Replace italics
body.css('i').each { |i| i.replace("*#{i.inner_text}*") }
body.css('em').each { |i| i.replace("*#{i.inner_text}*") }
-# Remove horizontal rules
-body.css('hr').remove
+# Replace horizontal rules
+body.css('hr').each { |hr| hr.replace "\n\n---\n\n" }
# Remove carriage returns
body.search('//text()').each do |text|
text.replace(text.text.gsub("\r", ''))