Commit 9ad0e7d2 authored by Miguel Angel Reina Ortega's avatar Miguel Angel Reina Ortega
Browse files

Preparation of spec before publishing

parent 4702387b
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
#!/bin/bash

DOCKER_IMAGE=pandoc/core:3.0
PANDOC_FILTER_DOCKER_IMAGE=pandocfilter:latest

echo "\n------ Checking for docker image --------"
docker pull "$DOCKER_IMAGE"
@@ -26,10 +27,11 @@ if [ ! $specs ] ; then
fi

for i in *.md ;  do
	echo "\n------ Preparaing spec --------" 
	docker run --rm -v $(pwd):/tmp/ -u $(id -u):$(id -g) "$PANDOC_FILTER_DOCKER_IMAGE" pandocFilter -o "/tmp/" "/tmp/$i"
	echo "\n------ Publishing spec --------" 
	docker run --rm -v $(pwd):/data -u $(id -u):$(id -g) "$DOCKER_IMAGE" "/data/$i" -f markdown -t docx --reference-doc "Spec-template.docx" -o "${PROJECT_NAME}_${2}.docx" 
done

echo "\n------ Publishing spec --------" 

exit 0
 No newline at end of file