meso-web

Sources of the |Méso|Star> website
git clone git://git.meso-star.fr/meso-web.git
Log | Files | Refs | README | LICENSE

commit 5304a583b085e7d44e8238879d51f7079b6920f9
parent 9a0c55962d323e3111b14fce0bca2e82b7c08b1f
Author: Vincent Forest <vincent.forest@meso-star.com>
Date:   Wed, 23 Feb 2022 15:32:05 +0100

stardis: upd build process

Remove intermediary "release notes" files

Diffstat:
Mstardis/Makefile | 27+++++++--------------------
Mstardis/stardis_build.sh | 22+++++++++++++++++++---
2 files changed, 26 insertions(+), 23 deletions(-)

diff --git a/stardis/Makefile b/stardis/Makefile @@ -137,28 +137,15 @@ consortium-en.html: consortium-en.html.in edf_logo.svg stardis_build.sh ################################################################################ # Download web pages ################################################################################ -stardis-downloads.html: $(STARDIS_SIG)\ - stardis-release-notes.html.in \ - stardis-green-release-notes.html.in \ - stardis-solver-release-notes.html.in \ +stardis-downloads.html:\ + $(STARDIS_SIG) \ + $(STARDIS_SOLVER_README) \ + $(STARDIS_README) \ + $(STARDIS_GREEN_README) \ stardis_build.sh @echo "Building $@" - @sh stardis_build.sh downloads > $@ - -stardis-release-notes.html.in: $(STARDIS_README) - @$(MARKDOWN) $(STARDIS_README) \ - | sed -n '/^<h2>Release notes<\/h2>/,/^<h2>License<\/h2>/p' \ - | sed -e '1d' -e '$$d' > $@ - -stardis-green-release-notes.html.in: $(STARDIS_GREEN_README) - @$(MARKDOWN) $(STARDIS_GREEN_README) \ - | sed -n '/^<h2>Release notes<\/h2>/,/^<h2>License<\/h2>/p' \ - | sed -e '1d' -e '$$d' > $@ - -stardis-solver-release-notes.html.in: $(STARDIS_SOLVER_README) - @$(MARKDOWN) $(STARDIS_SOLVER_README) \ - | sed -n '/^<h2>Release notes<\/h2>/,/^<h2>License<\/h2>/p' \ - | sed -e '1d' -e '$$d' > $@ + @sh stardis_build.sh downloads $(STARDIS_SOLVER_README) $(STARDIS_README) \ + $(STARDIS_GREEN_README) > $@ $(STARDIS_ARCH_FILES): @echo "Extracting data from $(STARDIS_ARCH)" diff --git a/stardis/stardis_build.sh b/stardis/stardis_build.sh @@ -43,6 +43,12 @@ consortium() downloads() { + if [ $# -lt 3 ]; then + printf "Usage: %s downloads <stardis-solver-release-notes> \ +<stardis-release-notes> <stardis-green-release-notes>\n" "$0" >&2 + exit 1 + fi + print_header Stardis Downloads echo '<header><h1>Download Stardis</h1></header>' @@ -54,13 +60,23 @@ downloads() echo "the archive corresponds to the version number of the Stardis-Solver" echo "library packaged into the archive.</p>" + solver_release_notes=$(${markdown} "$1" \ + | sed -n '/^<h2>Release notes<\/h2>/,/^<h2>License<\/h2>/p' \ + | sed -e '1d' -e '$d') + app_release_notes=$(${markdown} "$2" \ + | sed -n '/^<h2>Release notes<\/h2>/,/^<h2>License<\/h2>/p' \ + | sed -e '1d' -e '$d') + green_release_notes=$(${markdown} "$3" \ + | sed -n '/^<h2>Release notes<\/h2>/,/^<h2>License<\/h2>/p' \ + | sed -e '1d' -e '$d') + print_downloads Stardis "Linux" echo "<h2>Stardis-Solver Library release notes</h2>" - cat stardis-solver-release-notes.html.in + echo "${solver_release_notes}" echo "<h2>Stardis CLI release notes</h2>" - cat stardis-release-notes.html.in + echo "${app_release_notes}" echo "<h2>Stardis-Green CLI release notes</h2>" - cat stardis-green-release-notes.html.in + echo "${green_release_notes}" print_footer }