From a176f6999a2d33163365602fb56cae8711875e06 Mon Sep 17 00:00:00 2001 From: Kuninori Morimoto Date: Tue, 9 Feb 2021 10:24:56 +0900 Subject: scripts: add html_task.py Because current PeriJect is using scripts/myhtml.py to creating all HTML files, all files will be re-created if myhtml.py itself was updated. It is very verbose. This patch separates "task" from it. Signed-off-by: Kuninori Morimoto --- Makefile | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 2dfd7ed..df47fde 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,3 @@ -HTML = ./scripts/myhtml.py FIND = ./scripts/find.py ALLYAML = $(shell ${FIND} -all) PROJECT = $(subst ./,,$(shell cd ./projects; find -type d)) @@ -47,20 +46,27 @@ index.html: ${HTMLDIR} ${WIKIDIR}: mkdir -p $@ -${FILE}: ${HTML_OPTION2} ${HTML} +${HTML}: ${FILES} ./scripts/html_${CMD}.py ./scripts/html_base.py ./scripts/base.py echo $@ - ${HTML} ${HTML_OPTION1} ${HTML_OPTION2} > $@ + ./scripts/html_${CMD}.py ${OPTION} ${FILES} > $@ + +${FILE}: ${HTML_OPTION2} ./scripts/myhtml.py + echo $@ + ./scripts/myhtml.py ${HTML_OPTION1} ${HTML_OPTION2} > $@ loop: for list in ${LISTS}; do\ make PARAM=$${list} EXP1=${EXP1} EXP2="${EXP2}" ${TARGET};\ done; +myhtml: + make CMD=${CMD} OPTION="${OPTION}" FILES="${FILES}" HTML=${HTML} ${HTML} +file: + make CMD=task FILES=${PARAM} HTML=$(subst yaml,html,$(subst projects,html,${PARAM})) myhtml + basic: make HTML_OPTION1="${HTML_OPTION1}" HTML_OPTION2="${HTML_OPTION2}" FILE=${FILE} ${FILE} summary: make HTML_OPTION1=summary HTML_OPTION2=projects/${PARAM} FILE=html/${PARAM}/summary.html basic -file: - make HTML_OPTION1=task HTML_OPTION2=${PARAM} FILE=$(subst yaml,html,$(subst projects,html,${PARAM})) basic noparam: make HTML_OPTION1=${PARAM} HTML_OPTION2="${PRODIR}" FILE=html/${PARAM}.html basic finds: -- cgit v1.2.3