Commit 3d02e035 authored by Adrian DC's avatar Adrian DC
Browse files

docs(prepare): avoid 'md_in_html' changes to 'changelog' and 'license'

Signed-off-by: default avatarAdrian DC <radian.dc@gmail.com>
parent 648d9406
Loading
Loading
Loading
Loading
Loading
+8 −8
Changes for docs/prepare.sh: 8 added lines, 8 removed lines.
Original line number Diff line number Diff line
@@ -18,6 +18,14 @@ mkdir -p "${docs_path}/.cache/assets/images/"
# Export usage
cp -f "${root_path}/README.md" "${docs_path}/.cache/index.md"

# Bind 'md_in_html' extension
sed -i \
  -e 's/<\(details\)>/<\1 markdown>/g' \
  -e 's/<\(div style="padding-left: 30px"\)>/<\1 markdown>/g' \
  -e '/<div style="padding-left: 30px"/{ n; /<br/d; }' \
  "${docs_path}/.cache/"*.md \
  "${docs_path}/.cache/"*/*.md

# Export about/changelog
mkdir -p "${docs_path}/.cache/about/"
if ! type git-cliff >/dev/null 2>&1; then
@@ -35,14 +43,6 @@ diff -u "${root_path}/CHANGELOG.md" "${docs_path}/.cache/about/changelog.md" ||
  cat "${root_path}/LICENSE"
} >"${docs_path}/.cache/about/license.md"

# Bind 'md_in_html' extension
sed -i \
  -e 's/<\(details\)>/<\1 markdown>/g' \
  -e 's/<\(div style="padding-left: 30px"\)>/<\1 markdown>/g' \
  -e '/<div style="padding-left: 30px"/{ n; /<br/d; }' \
  "${docs_path}/.cache/"*.md \
  "${docs_path}/.cache/"*/*.md

# Show cache
echo ' '
ls -laR "${docs_path}/.cache/"