~stormdragon2976/bashtml

842ef7cc9ab4a86c0353644dd0f0f12aa00ac1f2 — Michael Taboada 1 year, 6 months ago 2edd290
Fix setting title to heading level 2.
1 files changed, 1 insertions(+), 1 deletions(-)

M bashtml.sh
M bashtml.sh => bashtml.sh +1 -1
@@ 498,7 498,7 @@ new_post() {
  # Get the final file name to pass to plugins.
  fileName="${pageName}.${settings[pageExtension]}"
  # make sure the first line (title) is a heading level 2.
  sed -i -e '1s/^\([[:space:][:alnum:]]\)/## [\1]($fileName)/' -e '1s/^#\+/##/' "$mdFile"
  sed -i -e "1s/\(.*\)/## [\1]($fileName)/" -e '1s/^#\+/##/' "$mdFile"
  # Add the header:
  add_header "$htmlFile"
  markdown "$mdFile" >> "$htmlFile"