Merge feat/power-calculator into main

This commit is contained in:
tth committed 2026-12-04 19:18:14 +01:00
commit 0f87f8a601
8 files changed
+1302 -3

No files matched your search

+6 -3
View File
@@ -33,12 +33,15 @@ rm -f "$stage/docs/docs.md" # how to build upstream's site, not for readers
# README of the fork: "## O tomto forku" .. "## About this fork" = Czech,
# from there to "## About MeshCore" = English. One heading level up, links
# into docs/ made site-relative, any other repo path absolute.
# into docs/ made site-relative, any other repo path absolute. The docs/
# links are marked (@) before the absolute rewrite and unmarked after it,
# otherwise that rewrite caught them too (src/branch/main/power.md, a 404).
readme_part() {
sed -n "/^## $1/,/^## $2/p" README.md | sed '$d' |
sed -E 's/^#(#+) /\1 /' |
sed -E 's#\]\((\./)?docs/([^)]+)\)#](\2)#g' |
sed -E "s#\\]\\((\\./)?([a-zA-Z][^):]*)\\)#](${src//#/\\#}/\\2)#g"
sed -E 's#\]\((\./)?docs/([^)]+)\)#](@\2)#g' |
sed -E "s#\\]\\((\\./)?([a-zA-Z][^):]*)\\)#](${src//#/\\#}/\\2)#g" |
sed -E 's#\]\(@#](#g'
}
readme_part 'About this fork' 'About MeshCore' >"$stage/docs/index.md"
readme_part 'O tomto forku' 'About this fork' >"$stage/docs/cs.md"