commit e65353b90524a062fc6a4ebe33a1d7aa134479a3
parent 0deccc208cd646b87a75dab4003bf0abbd7c89b7
Author: Vincent Forest <vincent.forest@meso-star.com>
Date: Mon, 30 Jun 2025 15:01:17 +0200
htrdr: further translation into markdown
Translate the documentation index and the Atmosphere Starter Pack. The
latter was built from the README of the starter pack already written in
Markdown, but edited directly in HTML, rather than following the
simplicity imposed by the use of Markdown.
Diffstat:
17 files changed, 143 insertions(+), 149 deletions(-)
diff --git a/htrdr/.gitignore b/htrdr/.gitignore
@@ -1,6 +1,8 @@
+htrdr.md
htrdr.html
htrdr-docs.html
htrdr-mods.html
+htrdr-atmosphere-spk.md
htrdr-atmosphere-spk.html
htrdr-combustion-spk.html
htrdr-planets-spk.html
diff --git a/htrdr/Makefile b/htrdr/Makefile
@@ -100,13 +100,18 @@ OVERVIEW_IMG=\
thumbs/titan_transit.jpg
ATMSPK_IMG=\
- DZVAR.jpg\
+ images/DZVAR.jpg\
+ images/DZVAR2.jpg\
+ images/L12km_BOMEX.jpg\
+ images/L25_Fire.jpg\
+ images/city_thin_lens.jpg\
+ thumbs/DZVAR.jpg\
+ thumbs/DZVAR2.jpg\
+ thumbs/L12km_BOMEX.jpg\
+ thumbs/L25_Fire.jpg\
+ thumbs/city_thin_lens.jpg \
DZVAR_ortho.jpg\
- DZVAR2.jpg\
- L12km_BOMEX.jpg\
- L25_Fire.jpg\
- city.jpg\
- city_thin_lens.jpg
+ city.jpg
COMSPK_IMG=\
dummy_medium.jpg\
@@ -140,6 +145,8 @@ clean:
@echo "Cleaning generated files"
@rm -rf man
@rm -f .sig .lint .man $(HTML) $(HTML:=.err)
+ @rm -f htrdr-atmosphere-spk.md
+ @rm -f htrdr.md
distclean: clean
@echo "Cleaning PGP signatures and extracted files"
@@ -173,12 +180,11 @@ htrdr_build.sh: ../meso-menu.sh
################################################################################
# Overview
################################################################################
-htrdr.html: \
- htrdr.md.in \
- $(HTRDR_README) \
- $(OVERVIEW_IMG) \
- htrdr_build.sh \
- Makefile
+htrdr.html: htrdr.md htrdr_build.sh
+ @echo "Building $@"
+ @$(SHELL) htrdr_build.sh overview2 > $@
+
+htrdr.md: htrdr.md.in $(HTRDR_README) $(OVERVIEW_IMG) htrdr_build.sh Makefile
@echo "Building $@"
@$(SHELL) htrdr_build.sh overview $(HTRDR_README) $(HTRDR_VERSION) > $@
@@ -189,14 +195,18 @@ $(HTRDR_README) $(MAN):
################################################################################
# Reference documentations
################################################################################
-htrdr-docs.html: htrdr-docs.html.in htrdr_build.sh
+htrdr-docs.html: htrdr-docs.md htrdr_build.sh
@echo "Building $@"
@$(SHELL) htrdr_build.sh documentations > $@
################################################################################
# Atmosphere Starter-Pack
################################################################################
-htrdr-atmosphere-spk.html: \
+htrdr-atmosphere-spk.html: htrdr-atmosphere-spk.md htrdr_build.sh
+ @echo "Building $@"
+ @$(SHELL) htrdr_build.sh atmspk2 > $@
+
+htrdr-atmosphere-spk.md: \
$(ATMSPK_IMG) \
$(ATMSPK_SIG) \
$(ATMSPK_README) \
diff --git a/htrdr/htrdr-docs.md b/htrdr/htrdr-docs.md
@@ -0,0 +1,43 @@
+# Reference documentation
+
+## Main commands
+
+- [htrdr(1)](man/man1/htrdr.1.html)
+- [htrdr-atmosphere(1)](man/man1/htrdr-atmosphere.1.html)
+- [htrdr-combustion(1)](man/man1/htrdr-combustion.1.html)
+- [htrdr-planets(1)](man/man1/htrdr-planets.1.html)
+
+## Additionnal tools
+
+- [htpp(1)](man/man1/htpp.1.html)
+- [les2htcp(1)](man/man1/les2htcp.1.html)
+
+## Common file formats
+
+- [htrdr-image(5)](man/man5/htrdr-image.5.html)
+- [htrdr-materials(5)](man/man5/htrdr-materials.5.html)
+- [htrdr-obj(5)](man/man5/htrdr-obj.5.html)
+- [mrumtl(5)](man/man5/mrumtl.5.html)
+- [sars(5)](man/man5/sars.5.html)
+- [sbuf(5)](man/man5/sbuf.5.html)
+- [sck(5)](man/man5/sck.5.html)
+- [smsh(5)](man/man5/smsh.5.html)
+
+## Describe a plane parallel atmosphere
+
+- [htmie(5)](man/man5/htmie.5.html)
+- [htcp(5)](man/man5/htcp.5.html)
+- [htgop](downloads/gas_opt_prop_en.pdf)
+
+## Describe a combustion medium
+
+- [atrri(5)](man/man5/atrri.5.html)
+- [atrtp(5)](man/man5/atrtp.5.html)
+
+## Describe a terrestrial planet
+
+- [rngt(5)](man/man5/rngt.5.html)
+- [rnpfi(5)](man/man5/rnpfi.5.html)
+- [rnrl(5)](man/man5/rnrl.5.html)
+- [rnsf(5)](man/man5/rnsf.5.html)
+- [rnsl(5)](man/man5/rnsl.5.html)
diff --git a/htrdr/htrdr_build.sh b/htrdr/htrdr_build.sh
@@ -17,6 +17,14 @@
. ../meso-menu.sh
+
+overview2()
+{
+ print_header -s htrdr -n Overview -r ../
+ md2html htrdr.md
+ print_footer
+}
+
overview()
{
if [ $# -lt 2 ]; then
@@ -24,37 +32,29 @@ overview()
exit 1
fi
- print_header -s htrdr -n Overview -r ../
- sed "s/@VERSION@/$2/g" htrdr.md.in | md2html
- sed -n '/## Release notes/,$p' "$1" \
+ {
+ sed -n '0,/^## History/p' htrdr.md.in | sed '$d';
+ sed -n '/^## Release notes/,/^## Copyright/p' "$1" | sed '$d';
+ sed -n '/^## History/,$p' htrdr.md.in;
+ sed -n '/^## Copyright/,$p' "$1";
+ } \
+ | sed "s/@VERSION@/$2/g" \
| sed 's/https:\/\/gitlab.com\/meso-star\/htrdr\/-\/blob\/master\/doc\/htrdr-materials\.5\.txt/man\/man5\/htrdr-materials.5.html/g' \
| sed 's/https:\/\/gitlab.com\/meso-star\/htrdr\/-\/blob\/master\/doc\/htrdr-obj\.5\.txt/man\/man5\/htrdr-obj.5.html/g' \
- | sed 's/https:\/\/gitlab.com\/meso-star\/mrumtl\/-\/blob\/master\/doc\/mrumtl\.5\.txt/man\/man5\/mrumtl.5.html/g' \
- | md2html
- print_footer
+ | sed 's/https:\/\/gitlab.com\/meso-star\/mrumtl\/-\/blob\/master\/doc\/mrumtl\.5\.txt/man\/man5\/mrumtl.5.html/g'
}
documentations()
{
print_header -s htrdr -n Documentations -r ../
- cat htrdr-docs.html.in
+ md2html htrdr-docs.md
print_footer
}
-mods()
+atmspk2()
{
- print_header -s htrdr -n Mods -r ../
-
- echo "<header>"
- echo " <h1>Modifications</h1>"
- echo "</header>"
-
- echo "<code>htrdr</code> is free software. Far from a simple <i>credo</i>,"
- echo "the user is invited to study, modify and redistribute it"
- echo "according to his own needs. This page lists some of these forks"
- echo "developed by the <code>htrdr</code> community."
-
- cat mods/htrdr-urban.html.in
+ print_header -s htrdr -n Atmosphere-Starter-Pack -r ../
+ md2html htrdr-atmosphere-spk.md
print_footer
}
@@ -65,125 +65,52 @@ atmspk()
exit 1
fi
- readme=$(${markdown} "$1" \
- | sed 's/https:\/\/gitlab.com\/meso-star\/htgop.git/downloads\/gas_opt_prop_en.pdf/g' \
- | sed 's/https:\/\/www.meso-star.com\/projects\/htrdr\/man\//man\//g' \
- | sed 's/https:\/\/www.meso-star.com\/projects\/htrdr\/downloads\/gas_opt_prop_en.pdf/downloads\/gas_opt_prop_en.pdf/g' \
- | sed 's/https:\/\/gitlab.com\/meso-star\/htcp.git/man\/man5\/htcp.5.html/g' \
- | sed 's/https:\/\/gitlab.com\/meso-star\/htmie.git/man\/man5\/htmie.5.html/g' \
- | sed 's/https:\/\/gitlab.com\/meso-star\/htpp.git/man\/man1\/htpp.1.html/g' \
- | sed 's/https:\/\/gitlab.com\/meso-star\/htrdr.git/man\/man1\/htrdr.1.html/g' \
- | sed 's/<pre><code>/<pre class="code">/g' \
- | sed 's/<\/code><\/pre>/<\/pre>/g')
-
- intro=$(echo "${readme}" | sed -e '1d' -e '/^<h2>Content<\/h2>/,$d')
- content1=$(echo "${readme}" \
- | sed -n '/^<h2>Content<\/h2>/,/^<h3>Geometries<\/h3>/p' \
- | sed -e '1d' -e '$d')
- content2=$(echo "${readme}" \
- | sed -n '/^<h3>Geometries<\/h3>/,/^<h3>Ground materials<\/h3>/p' \
- | sed '$d')
- content3=$(echo "${readme}" \
- | sed -n '/^<h3>Ground materials<\/h3>/,/^<h2>Quick start<\/h2>/p' \
- | sed '$d')
- quick_start=$(echo "${readme}" \
- | sed -n '/^<h2>Quick start<\/h2>/,/^<h2>Release notes<\/h2>/p' \
- | sed -e '1d' -e '$d')
- release_notes=$(echo "${readme}" \
- | sed -n '/^<h2>Release notes<\/h2>/,/^<h2>Copyright notice<\/h2>/p' \
- | sed -e '1d' -e '$d' -e 's/ gemetry / geometry /')
- copying=$(echo "${readme}" \
- | sed -n '/^<h2>Copyright notice<\/h2>/,$p' \
- | sed -e 's/from/from the/' -e 's/opyright (C)/opyright \©/')
-
- archs=$(find downloads -name "htrdr-Atmosphere-Starter-Pack*.tar.gz" | sort -r)
- archs=$(echo "${archs}" && find downloads -name "High-Tune-Starter-Pack*.tar.gz" | sort -r )
-
- print_header -s htrdr -n Atmosphere-Starter-Pack -r ../
+ sed -n '0,/^## Content/p' "$1" | sed '$d' # Intro
- echo "<header>"
- echo " <h1>Atmosphere Starter Pack</h1>"
- echo "</header>"
- echo "<div class=\"news\">"
- echo " <p><b>Atmosphere Starter Pack $2</b></p>"
- echo " <ul>"
- echo " <li><a href=\"downloads/htrdr-Atmosphere-Starter-Pack-$2.tar.gz\">tarball</a> /"
- echo " <a href=\"downloads/htrdr-Atmosphere-Starter-Pack-$2.tar.gz.sig\">pgp</a></li>"
- echo " </ul>"
- echo "</div>"
+ printf '[](images/city_thin_lens.jpg)\n'
+ printf '\n'
+ printf '> The image of the city scene rendered with\n'
+ printf '> `htrdr-atmosphere`.\n'
+ printf '> The thin lens camera used in this rendering focuses on\n'
+ printf '> background elements; the foreground vegetation is out of focus.\n'
+ printf '\n'
- echo "${intro}"
+ printf '## Downloads\n'
- echo "<h2>Content</h2>"
- echo "<div class=\"img\" style=\"padding-top:3em; width: 17em\">"
- echo " <a href=\"DZVAR.jpg\"><img src=\"DZVAR.jpg\" alt=\"DZVAR\"></a>"
- echo " <a href=\"DZVAR2.jpg\"><img src=\"DZVAR2.jpg\" alt=\"DZVAR2\"></a>"
- echo " <a href=\"L12km_BOMEX.jpg\"><img src=\"L12km_BOMEX.jpg\" alt=\"L12_BOMEX\"></a>"
- echo " <a href=\"L25_Fire.jpg\"><img src=\"L25_Fire.jpg\" alt=\"L25_Fire\"></a>"
- echo " <div class=\"caption\">"
- echo " Images of the DZVAR, DZVAR2, L12km_BOMEX and L25_Fire scenes"
- echo " rendered with <code>htrdr-atmosphere</code>."
- echo " </div>"
- echo "</div>"
+ archs=$(find downloads -name "htrdr-Atmosphere-Starter-Pack*.tar.gz" \
+ -o -name "High-Tune-Starter-Pack*.tar.gz" | sort -r)
- echo "${content1}"
+ printf '<table class="list">\n'
+ printf ' <tr><th>Version</th><th>Archive</th></tr>\n'
- echo "<div class=\"img\" style=\"margin-top:3em; width: 17em;\">"
- echo " <a href=\"city_thin_lens.jpg\"><img src=\"city_thin_lens.jpg\" alt=\"city_thin_lens\"></a>"
- echo " <div class=\"caption\">"
- echo " The image of the city scene rendered with"
- echo " <code>htrdr-atmosphere</code>. The thin lens camera used in this"
- echo " rendering focuses on background elements; the foreground vegetation"
- echo " is out of focus."
- echo " </div>"
- echo "</div>"
-
- echo "${content2}"
-
- echo "<div class=\"img\" style=\"margin-top:3em; width: 13em;\">"
- echo " <a href=\"DZVAR_ortho.jpg\"><img src=\"DZVAR_ortho.jpg\" alt=\"DZVAR_ortho\"></a>"
- echo " <div class=\"caption\">"
- echo " Image of the DZVAR cloud field rendered from the top of the"
- echo " atmosphere with an orthographic camera."
- echo " </div>"
- echo "</div>"
-
- echo "${content3}"
-
- echo "<h2>Install and run</h2>"
- echo ""
- echo "<p>Download the Atmosphere Starter-Pack archive and verify"
- echo "its integrity against its <a href=\"../misc/pgp_signatures.html\">PGP"
- echo "signature</a>. Then extract it."
- echo "${quick_start}"
-
- echo "<h2>Donwloads</h2>"
-
- echo "<table class=\"list\">"
- echo " <tr>"
- echo " <th>Version</th>"
- echo " <th>Archive</th>"
- echo " </tr>"
-
- echo "${archs}" |
+ printf '%s\n' "${archs}" | \
while read -r i ; do
version=$(echo "${i}" | sed "s/.*Starter-Pack-\(.*\)\.tar.gz/\1/g")
- echo " <tr>"
- echo " <td>${version}</td>"
- echo " <td>"
- echo " [<a href=\"${i}\">tarball</a>]"
- if [ -f "${i}.sig" ]; then
- echo " [<a href=\"${i}.sig\">pgp</a>]"
- fi
- echo " </td>"
- echo " </tr>"
+ printf ' <tr>\n'
+ printf ' <td>%s</td>\n' "${version}"
+ printf ' <td>\n'
+ printf ' [<a href="%s">tarball</a>]\n' "${i}"
+ printf ' [<a href="%s.sig">pgp</a>]\n' "${i}"
+ printf ' </td>\n'
+ printf ' </tr>\n'
done
- echo "</table>"
+ printf '</table>\n\n'
- echo "${release_notes}"
- echo "${copying}"
+ sed -n '/^## Quick start/,/^## Release notes/p' "$1" | sed '$d'
- print_footer
+ sed -n '/^## Content/,/^### Water/p' "$1" | sed '$d'
+
+ printf '[](images/DZVAR.jpg)\n\n'
+ printf '[](images/DZVAR2.jpg)\n\n'
+ printf '[](images/L12km_BOMEX.jpg)\n\n'
+ printf '[](images/L25_Fire.jpg)\n\n'
+ printf '\n'
+ printf '> Images of the DZVAR, DZVAR2, L12km_BOMEX and L25_Fire scenes\n'
+ printf '> rendered with `htrdr-atmosphere`.\n'
+
+ sed -n '/^### Water/,/^## Quick start/p' "$1" | sed '$d'
+
+ sed -n '/^## Release notes/,$p' "$1"
}
comspk()
diff --git a/htrdr/images/DZVAR.jpg b/htrdr/images/DZVAR.jpg
@@ -0,0 +1 @@
+#$# git-wad 6a5c610c6460b754b05495db98cc484b05ded0fd38f6e66019b554235949a53b 485786
+\ No newline at end of file
diff --git a/htrdr/images/DZVAR2.jpg b/htrdr/images/DZVAR2.jpg
@@ -0,0 +1 @@
+#$# git-wad 4af4cccecf3c36d4cb26237d0f568d92eb8733795b88b35fb1a11065388c8945 371146
+\ No newline at end of file
diff --git a/htrdr/images/L12km_BOMEX.jpg b/htrdr/images/L12km_BOMEX.jpg
@@ -0,0 +1 @@
+#$# git-wad af6c079e62f1d4ea52163dc8b75c43b1acce84e90cf698dbd77d83881b7e5935 656825
+\ No newline at end of file
diff --git a/htrdr/images/L25_Fire.jpg b/htrdr/images/L25_Fire.jpg
@@ -0,0 +1 @@
+#$# git-wad 7d28c4190db608076c2b54c150b14d5fdbbc137e711d9755efc6455a2e2d2dff 243365
+\ No newline at end of file
diff --git a/htrdr/city_thin_lens.jpg b/htrdr/images/city_thin_lens.jpg
diff --git a/htrdr/thumbs/DZVAR.jpg b/htrdr/thumbs/DZVAR.jpg
@@ -0,0 +1 @@
+#$# git-wad 6fad6b45818270930dc325d57589e462c979986b050f0fbadcf031a1f54b4b4a 34469
+\ No newline at end of file
diff --git a/htrdr/thumbs/DZVAR2.jpg b/htrdr/thumbs/DZVAR2.jpg
@@ -0,0 +1 @@
+#$# git-wad b1e7e52d30c8e1af622aac2e330cee90c8e617f04a14150f9188f803cb97ab80 22192
+\ No newline at end of file
diff --git a/htrdr/thumbs/L12km_BOMEX.jpg b/htrdr/thumbs/L12km_BOMEX.jpg
@@ -0,0 +1 @@
+#$# git-wad 14f8048431a749403dfc16da0365999fa9bbc12467f76adaa853b91d67c196a1 35194
+\ No newline at end of file
diff --git a/htrdr/thumbs/L25_Fire.jpg b/htrdr/thumbs/L25_Fire.jpg
@@ -0,0 +1 @@
+#$# git-wad 5e600228f17ff0ba0e351848598aac0a098dc36615303103996890d67a2ed5de 13088
+\ No newline at end of file
diff --git a/htrdr/thumbs/black.jpg b/htrdr/thumbs/black.jpg
@@ -1 +0,0 @@
-#$# git-wad 518628c05a94d65ef74c29d149706628da442b845b69c984ad7fa1e783658808 1686
-\ No newline at end of file
diff --git a/htrdr/thumbs/black.png b/htrdr/thumbs/black.png
@@ -1 +0,0 @@
-#$# git-wad 208a4b3515dbf8c799f762ba001327e6c5ffb4c5f31c8f24a8b819edf232164e 1430
-\ No newline at end of file
diff --git a/htrdr/thumbs/city_thin_lens.jpg b/htrdr/thumbs/city_thin_lens.jpg
@@ -0,0 +1 @@
+#$# git-wad be30725b58315c2b2631e94efce9cf9d1a00ddc901326cc17029ebc7d1cf5bb7 91893
+\ No newline at end of file
diff --git a/htrdr/thumbs/titan_1280x960x4096_2.jpg.jpg b/htrdr/thumbs/titan_1280x960x4096_2.jpg.jpg
@@ -1 +0,0 @@
-#$# git-wad c94e2a6d072802983241e05bd8334e558e65eeef2a9fa9f67daedef410eb98d6 25905
-\ No newline at end of file