diff --git a/.gitmodules b/.gitmodules index fa6b8be..415748d 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,3 +1,6 @@ [submodule "cgi-bin/exportArticle/templates"] path = cgi-bin/exportArticle/templates + url = git@framagit.org:ecrinum/templates-stylo.git +[submodule "cgi-bin/exportArticleSP/templates"] + path = cgi-bin/exportArticleSP/templates url = git@framagit.org:ecrinum/templates-sp.git diff --git a/cgi-bin/exportArticle/exec.cgi b/cgi-bin/exportArticle/exec.cgi index 9d0a621..098d035 100755 --- a/cgi-bin/exportArticle/exec.cgi +++ b/cgi-bin/exportArticle/exec.cgi @@ -22,29 +22,25 @@ IFS=$saveIFS declare -A GET for ((i=0; i<${#parm[@]}; i+=2)) do - GET[${parm[i]}]=${parm[i+1]} + GET[${parm[i]}]=${parm[i+1]} done #Assign defaults endpoint="Version" -echo "

id : ${GET[id]}
Article : ${GET[article]}
Version : ${GET[version]}
Processor : ${GET[processor]}

" +echo "

id : ${GET[id]}
Article : ${GET[article]}
Version : ${GET[version]}
Format : ${GET[format]}
Bibliographical style : ${GET[bibstyle]}
Processor : ${GET[processor]}

" #exiting if either id or version not specified if [ -z "${GET[id]}" ]; then - echo "No id specified"; - echo "" - exit 1 + echo "No id specified"; + echo "" + exit 1 fi -#if [ -n "${GET[article]}"]; then -# GET[version]=${GET[article]} -# echo "THis is an article" -# endpoint="Article" -#fi + if [ -z "${GET[version]}" ]; then - echo "No version specified"; - echo "" - exit 1 + echo "No version specified"; + echo "" + exit 1 fi #Relocate script + create folder for that version @@ -61,62 +57,77 @@ rm ${GET[id]}.zip rename "s/${GET[version]}/${GET[id]}/g" * sed -i -e "s/\/${GET[version]}/${GET[id]}/g" ${GET[id]}.yaml -pandoc --standalone --template=../templates/templateHtmlDcV2.html5 --ascii --filter pandoc-citeproc -f markdown -t html ${GET[id]}.md ${GET[id]}.yaml --csl ../templates/chicagomodified.csl -o ${GET[id]}.html - -pandoc --standalone --filter pandoc-citeproc --table-of-contents --template=../templates/templateLaTeX.latex -f markdown -t latex ${GET[id]}.md ${GET[id]}.yaml -o ${GET[id]}.md.tex sed -i -e 's/https:\/\/i\.imgur.com\//media\//g' ${GET[id]}.md -sed -i -e 's/https:\/\/i\.imgur.com\//media\//g' ${GET[id]}.html -sed -i -e 's/https:\/\/i\.imgur.com\//media\//g' ${GET[id]}.md.tex + if find media/ -mindepth 1 -print -quit 2>/dev/null | grep -q .; then -cd media -COUNTER=0 -for filename in "$3"*; do - COUNTER=$[$COUNTER +1] - echo "${filename%.*}" - sed -i -e "s@${filename%.*}@${GET[id]}\-img${COUNTER}@g" ../${GET[id]}.md - sed -i -e "s@${filename%.*}@${GET[id]}\-img${COUNTER}@g" ../${GET[id]}.md.tex - sed -i -e "s@${filename%.*}@${GET[id]}\-img${COUNTER}@g" ../${GET[id]}.html - mv ${filename%.*}.${filename##*.} ${GET[id]}-img${COUNTER}.${filename##*.} -done -cd .. + cd media + COUNTER=0 + for filename in "$3"*; do + COUNTER=$[$COUNTER +1] + echo "${filename%.*}" + sed -i -e "s@${filename%.*}@${GET[id]}\-img${COUNTER}@g" ../${GET[id]}.md + # not usefull if the html and the tex are made after renaming images in the md file + # sed -i -e "s@${filename%.*}@${GET[id]}\-img${COUNTER}@g" ../${GET[id]}.md.tex + # sed -i -e "s@${filename%.*}@${GET[id]}\-img${COUNTER}@g" ../${GET[id]}.html + mv ${filename%.*}.${filename##*.} ${GET[id]}-img${COUNTER}.${filename##*.} + done + cd .. fi -#Copy assets in the /media files -cp -r ../assets/* ./media +#Copy assets in the /media files: uncomment if there are any images to include (for example a logo) +# cp -r ../assets/* ./media +preparefiles () +{ + echo "
Getting ${GET[format]} file ready"
+	echo "
" -#create PDF using processor -if [ "${GET[processor]}" = "pdflatex" ]; then - pdflatex ${GET[id]}.md.tex >> bash.log - pdflatex ${GET[id]}.md.tex >> bash.log -else - xelatex ${GET[id]}.md.tex >> bash.log - xelatex ${GET[id]}.md.tex >> bash.log -fi + #Zip all files and move ZIP and PDF to export + echo "
Getting ZIP file ready"
+	zip -r ${GET[id]}.zip .
+	echo "
" + mv ${GET[id]}.zip /usr/local/apache2/htdocs/export/ + mv ${GET[id]}.${GET[format]} /usr/local/apache2/htdocs/export/ + #Clean folder + cd .. + rm -R ${GET[version]} + + echo "
" + echo "${GET[format]} : /export/${GET[id]}.${GET[format]}
" + + echo "ZIP : /export/${GET[id]}.zip
" -#Create erudit XML from HTML -java -jar /usr/local/vendor/saxon9he.jar -s:${GET[id]}.html -xsl:../templates/XHTML2eruditV2.xsl -o:${GET[id]}.erudit.xml +} -#Zip all files and move ZIP and PDF to export -echo "
Getting ZIP file ready"
-zip -r ${GET[id]}.zip .
-echo "
" -mv ${GET[id]}.zip /usr/local/apache2/htdocs/export/ -mv ${GET[id]}.md.pdf /usr/local/apache2/htdocs/export/ -#Clean folder -cd .. -rm -R ${GET[version]} +case "${GET[format]}" in +pdf) pandoc --standalone --filter pandoc-citeproc --table-of-contents -f markdown -t latex --latex-engine=xelatex --csl ../templates/${GET[bibstyle]}.csl ${GET[id]}.md ${GET[id]}.yaml -o ${GET[id]}.pdf >> bash.log;; +html) pandoc --standalone --filter pandoc-citeproc --table-of-contents -f markdown -t ${GET[format]} --csl ../templates/${GET[bibstyle]}.csl ${GET[id]}.md ${GET[id]}.yaml -o ${GET[id]}.${GET[format]} >> bash.log;; +docx) pandoc --standalone --filter pandoc-citeproc --table-of-contents -f markdown -t ${GET[format]} --csl ../templates/${GET[bibstyle]}.csl ${GET[id]}.md ${GET[id]}.yaml -o ${GET[id]}.${GET[format]} >> bash.log;; +odt) pandoc --standalone --filter pandoc-citeproc --table-of-contents -f markdown -t ${GET[format]} --csl ../templates/${GET[bibstyle]}.csl ${GET[id]}.md ${GET[id]}.yaml -o ${GET[id]}.${GET[format]} >> bash.log;; +tei) pandoc --standalone --filter pandoc-citeproc --table-of-contents -f markdown -t ${GET[format]} --csl ../templates/${GET[bibstyle]}.csl ${GET[id]}.md ${GET[id]}.yaml -o ${GET[id]}.${GET[format]} >> bash.log;; +*) echo "not working";; +esac + +#if [ "${GET[format]}" = "pdf" ]; then +# pandoc --standalone --filter pandoc-citeproc --table-of-contents -f markdown -t latex --latex-engine=xelatex --csl ../templates/${GET[bibstyle]}.csl ${GET[id]}.md ${GET[id]}.yaml -o ${GET[id]}.pdf >> bash.log + + preparefiles + +#else +# pandoc --standalone --filter pandoc-citeproc --table-of-contents -f markdown -t ${GET[format]} --csl ../templates/${GET[bibstyle]}.csl ${GET[id]}.md ${GET[id]}.yaml -o ${GET[id]}.${GET[format]} >> bash.log + +# preparefiles + +#fi + -echo "
" -echo "PDF : /export/${GET[id]}.md.pdf
" -echo "ZIP : /export/${GET[id]}.zip
" echo "" diff --git a/cgi-bin/exportArticleSP/assets/crochets.png b/cgi-bin/exportArticleSP/assets/crochets.png new file mode 100644 index 0000000..78daa78 Binary files /dev/null and b/cgi-bin/exportArticleSP/assets/crochets.png differ diff --git a/cgi-bin/exportArticleSP/assets/logo.png b/cgi-bin/exportArticleSP/assets/logo.png new file mode 100644 index 0000000..335dbd8 Binary files /dev/null and b/cgi-bin/exportArticleSP/assets/logo.png differ diff --git a/cgi-bin/exportArticleSP/exec.cgi b/cgi-bin/exportArticleSP/exec.cgi new file mode 100755 index 0000000..9d0a621 --- /dev/null +++ b/cgi-bin/exportArticleSP/exec.cgi @@ -0,0 +1,122 @@ +#!/bin/bash + +#Quick parameters links +#version="5b2bc423e5842b0011ac871a" +#id="default" +#processor="xelatex" + +export HOME="/usr/local/apache2/cgi-bin" + + +echo "Content-type: text/html" +echo "" + +echo "Demo" + +#Assign parameters : exec.cgi?id=SP002&version=5b2be647e5842b0011ac874d&processor=pdflatex +#returns ${GET[id]} ${GET[version]} ${GET[processor]} +saveIFS=$IFS +IFS='=&' +parm=($QUERY_STRING) +IFS=$saveIFS +declare -A GET +for ((i=0; i<${#parm[@]}; i+=2)) +do + GET[${parm[i]}]=${parm[i+1]} +done + +#Assign defaults +endpoint="Version" + +echo "

id : ${GET[id]}
Article : ${GET[article]}
Version : ${GET[version]}
Processor : ${GET[processor]}

" + +#exiting if either id or version not specified +if [ -z "${GET[id]}" ]; then + echo "No id specified"; + echo "" + exit 1 +fi +#if [ -n "${GET[article]}"]; then +# GET[version]=${GET[article]} +# echo "THis is an article" +# endpoint="Article" +#fi +if [ -z "${GET[version]}" ]; then + echo "No version specified"; + echo "" + exit 1 +fi + +#Relocate script + create folder for that version +cd "$(dirname "$0")" +mkdir ${GET[version]} +cd ${GET[version]} + +curl -o ${GET[id]}.zip https://stylo.ecrituresnumeriques.ca/api/v1/zip${endpoint}/${GET[version]} +# curl -o ${GET[id]}.html https://stylo.ecrituresnumeriques.ca/api/v1/html${endpoint}/${GET[version]} +wget -nd -p -H -P media/ -A jpeg,jpg,bmp,gif,png -e robots=off https://stylo.ecrituresnumeriques.ca/api/v1/htmlVersion/${GET[version]} +unzip ${GET[id]}.zip >> bash.log +rm ${GET[id]}.zip + +rename "s/${GET[version]}/${GET[id]}/g" * +sed -i -e "s/\/${GET[version]}/${GET[id]}/g" ${GET[id]}.yaml + +pandoc --standalone --template=../templates/templateHtmlDcV2.html5 --ascii --filter pandoc-citeproc -f markdown -t html ${GET[id]}.md ${GET[id]}.yaml --csl ../templates/chicagomodified.csl -o ${GET[id]}.html + +pandoc --standalone --filter pandoc-citeproc --table-of-contents --template=../templates/templateLaTeX.latex -f markdown -t latex ${GET[id]}.md ${GET[id]}.yaml -o ${GET[id]}.md.tex + + +sed -i -e 's/https:\/\/i\.imgur.com\//media\//g' ${GET[id]}.md +sed -i -e 's/https:\/\/i\.imgur.com\//media\//g' ${GET[id]}.html +sed -i -e 's/https:\/\/i\.imgur.com\//media\//g' ${GET[id]}.md.tex + + + +if find media/ -mindepth 1 -print -quit 2>/dev/null | grep -q .; then +cd media +COUNTER=0 +for filename in "$3"*; do + COUNTER=$[$COUNTER +1] + echo "${filename%.*}" + sed -i -e "s@${filename%.*}@${GET[id]}\-img${COUNTER}@g" ../${GET[id]}.md + sed -i -e "s@${filename%.*}@${GET[id]}\-img${COUNTER}@g" ../${GET[id]}.md.tex + sed -i -e "s@${filename%.*}@${GET[id]}\-img${COUNTER}@g" ../${GET[id]}.html + mv ${filename%.*}.${filename##*.} ${GET[id]}-img${COUNTER}.${filename##*.} +done +cd .. +fi + + +#Copy assets in the /media files +cp -r ../assets/* ./media + + +#create PDF using processor +if [ "${GET[processor]}" = "pdflatex" ]; then + pdflatex ${GET[id]}.md.tex >> bash.log + pdflatex ${GET[id]}.md.tex >> bash.log +else + xelatex ${GET[id]}.md.tex >> bash.log + xelatex ${GET[id]}.md.tex >> bash.log +fi + +#Create erudit XML from HTML +java -jar /usr/local/vendor/saxon9he.jar -s:${GET[id]}.html -xsl:../templates/XHTML2eruditV2.xsl -o:${GET[id]}.erudit.xml + +#Zip all files and move ZIP and PDF to export +echo "
Getting ZIP file ready"
+zip -r ${GET[id]}.zip .
+echo "
" +mv ${GET[id]}.zip /usr/local/apache2/htdocs/export/ +mv ${GET[id]}.md.pdf /usr/local/apache2/htdocs/export/ + +#Clean folder +cd .. +rm -R ${GET[version]} + +echo "
" +echo "PDF : /export/${GET[id]}.md.pdf
" +echo "ZIP : /export/${GET[id]}.zip
" + + +echo "" diff --git a/cgi-bin/exportArticleSP/templates b/cgi-bin/exportArticleSP/templates new file mode 160000 index 0000000..07dfef3 --- /dev/null +++ b/cgi-bin/exportArticleSP/templates @@ -0,0 +1 @@ +Subproject commit 07dfef3cf5c0455fd3ef1c35ded6790eb5a63fb4 diff --git "a/cgi-bin/exportArticleSP/templates-old/Document 1 non enregistr\303\251" "b/cgi-bin/exportArticleSP/templates-old/Document 1 non enregistr\303\251" new file mode 100644 index 0000000..71ba6d3 --- /dev/null +++ "b/cgi-bin/exportArticleSP/templates-old/Document 1 non enregistr\303\251" @@ -0,0 +1,12 @@ +XSLT : + +traitement des images à partir des XML : + +concaténer les légendes + les sources dans le caption + + +Balise indice à prendre en compte + + +biblios : quand il y a des commentaires, on met une balise alinea + diff --git a/cgi-bin/exportArticleSP/templates-old/XHTML2eruditV1.xsl b/cgi-bin/exportArticleSP/templates-old/XHTML2eruditV1.xsl new file mode 100644 index 0000000..39159f7 --- /dev/null +++ b/cgi-bin/exportArticleSP/templates-old/XHTML2eruditV1.xsl @@ -0,0 +1,591 @@ + + + + +
+ + + article + + + autre + + + + + + + + + oui + + + + + + + + + + + + + + http://rameau.bnf.fr + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + sp + + + + + + + + + + masculin + + + + + feminin + + + + + + + + + + + + + + + + + + + masculin + + + + + feminin + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + masculin + + + + + feminin + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + + + + + + + + + + + + + + + + + + figure + + + simple + + + + + + + + + + +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Bibliographie + + + + + + + + + + + +
\ No newline at end of file diff --git a/cgi-bin/exportArticleSP/templates-old/teiV0.template b/cgi-bin/exportArticleSP/templates-old/teiV0.template new file mode 100644 index 0000000..d032576 --- /dev/null +++ b/cgi-bin/exportArticleSP/templates-old/teiV0.template @@ -0,0 +1,87 @@ + + + + + + + + $title$ + $for(authors)$ + + + + $authors.forname$ + $authors.surname$ + http://www.orcid.org/$authors.orcid$ + + + + + + + $endfor$ + + + + Département des littératures de langue française + $day$/$month$/$year$ + +

$rights$

+
+
+ +

No source, born digital.

+
+
+ + +

Sens public

+
+
+ + + $lang$ + + + + + $for(controlledKeywords)$ + $controlledKeywords.label$ + $endfor$ + $for(keyword_fr)$ + $keyword_fr$ + $endfor$ + + + $for(keyword_en)$ + $keyword_en$ + $endfor$ + + + + + + +
+ + + $for(abstract)$ +

$abstract.text$

+ $endfor$ +
+ + + $body$ + + + +
+ + + + +
+
+
+
diff --git a/cgi-bin/exportArticleSP/templates-old/templateHtmlDcV0.html5 b/cgi-bin/exportArticleSP/templates-old/templateHtmlDcV0.html5 new file mode 100644 index 0000000..e7ec524 --- /dev/null +++ b/cgi-bin/exportArticleSP/templates-old/templateHtmlDcV0.html5 @@ -0,0 +1,234 @@ + + + + + + + + + + +$if(lang)$ + +$endif$ +$if(url_article_sp)$ + +$endif$ + + + + + + +$if(url_article_sp)$ + +$endif$ +$if(issnnum)$ + +$endif$ + + + + + + + + +$if(authors)$ +$for(authors)$ + + $endfor$ +$endif$ +$if(abstract)$ +$for(abstract)$ + + +$endfor$ +$endif$ + + + +$if(keyword_fr)$ + +$endif$ + +$if(keyword_en)$ + +$endif$ + +$if(controlledKeywords)$ +$for(controlledKeywords)$ + +$endfor$ +$endif$ + + + + + + + + + + +$for(authors)$ + +$endfor$ + + + + + + + + + + +$if(abstract)$ +$for(abstract)$ + + +$endfor$ +$endif$ + +$if(translator)$ +$for(translator)$ + +$endfor$ +$endif$ + + + + + + + + +$if(redacteurDossier)$ +$for(redacteurDossier)$ + +$endfor$ +$endif$ + + + + + + + + + + + +$if(url_article_sp)$ + +$endif$ +$if(issnnum)$ + +$endif$ + + + + + +$for(authors)$ + +$endfor$ + +$if(abstract)$ +$for(abstract)$ + + +$endfor$ +$endif$ + + +$if(controlledKeywords)$ +$for(controlledKeywords)$ + + +$endfor$ +$endif$ + + + + + + + + + + +$if(controlledKeywords)$ +$for(controlledKeywords)$ + +$endfor$ +$endif$ + +$if(director)$ +$for(director)$ + +$endfor$ +$endif$ + +$if(authors)$ +$for(authors)$ + +$endfor$ +$endif$ + + +$if(redacteurDossier)$ +$for(redacteurDossier)$ + +$endfor$ +$endif$ + +$if(year)$ + +$endif$ + + $if(title-prefix)$$title-prefix$ – $endif$$pagetitle$ + +$if(quotes)$ + +$endif$ +$if(highlighting-css)$ + +$endif$ +$for(css)$ + +$endfor$ +$if(math)$ + $math$ +$endif$ +$for(header-includes)$ + $header-includes$ +$endfor$ + + +$for(include-before)$ +$include-before$ +$endfor$ +$if(toc)$ +
+$toc$ +
+$endif$ +$body$ +$for(include-after)$ +$include-after$ +$endfor$ + + diff --git a/cgi-bin/exportArticleSP/templates-old/templateHtmlDcV2-preview.html5 b/cgi-bin/exportArticleSP/templates-old/templateHtmlDcV2-preview.html5 new file mode 100644 index 0000000..6cd6f84 --- /dev/null +++ b/cgi-bin/exportArticleSP/templates-old/templateHtmlDcV2-preview.html5 @@ -0,0 +1,824 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + $if(subtitle)$ + + $endif$ + + + + + + + + + + + + $if(url_article_sp)$ + + $endif$ + $if(url_article_sp)$ + + $endif$ + $if(issnnum)$ + + $endif$ + + + $if(director)$ + $for(director)$ + + + + $endfor$ + $endif$ + + + $if(authors)$ + $for(authors)$ + + + $endfor$ + $endif$ + + + $if(abstract)$ + $for(abstract)$ + + + $endfor$ + $endif$ + + + $if(keyword_fr)$ + + $endif$ + + $if(keyword_en)$ + + $endif$ + + $if(controlledKeywords)$ + $for(controlledKeywords)$ + $if(controlledKeywords.label)$ + + $endif$ + $endfor$ + $endif$ + + + $if(translator)$ + $for(translator)$ + + + $endfor$ + $endif$ + + + + $if(transcriber)$ + $for(transcriber)$ + + + $endfor$ + $endif$ + + + $if(redacteurDossier)$ + $for(redacteurDossier)$ + + + $endfor$ + $endif$ + + + $if(toc)$ + $for(toc)$ + + $endfor$ + $endif$ + + + + + + $for(authors)$ + + $endfor$ + + $if(subtitle)$ + + $endif$ + + + + + + + + $if(abstract)$ + $for(abstract)$ + + $endfor$ + $endif$ + + $if(keyword_fr)$ + + $endif$ + + $if(keyword_en)$ + + $endif$ + + + + + + + + + + + + + + + + + + + + + $if(url_article_sp)$ + + $endif$ + $if(issnnum)$ + + $endif$ + + + $if(subtitle)$ + + $endif$ + + + + + + + + + $for(authors)$ + + $endfor$ + + $if(translator)$ + $for(translator)$ + + $endfor$ + $endif$ + + $if(transcriber)$ + $for(transcriber)$ + + $endfor$ + $endif$ + + $if(abstract)$ + $for(abstract)$ + + $endfor$ + $endif$ + + $if(controlledKeywords)$ + $for(controlledKeywords)$ + $if(controlledKeywords.label)$ + + + $endif$ + $endfor$ + $endif$ + + + + + + + $if(title-prefix)$$title-prefix$ – $endif$$pagetitle$$if(subtitle)$ : $subtitle$$endif$ + + + + $if(quotes)$ + + $endif$ + $if(highlighting-css)$ + + $endif$ + $for(css)$ + + $endfor$ + $if(math)$ + $math$ + $endif$ + $for(header-includes)$ + $header-includes$ + $endfor$ + + + + + + +
+

Stylo

+
+ $for(include-before)$ + $include-before$ + $endfor$ + $if(toc)$ +
+ $toc$ +
+ $endif$ + + + +
+ + $if(authors)$ + $for(authors)$ +
+
+ $authors.surname$ + $authors.forname$ + $authors.orcid$ +
+
+ $endfor$ + $endif$ + + + $if(redacteurDossier)$ + $for(redacteurDossier)$ +
+
+ $redacteurDossier.surname$ + $redacteurDossier.forname$ + $redacteurDossier.gender$ + $redacteurDossier.orcid$ +
+
+ $endfor$ + $endif$ + + + $if(director)$ + $for(director)$ +
+
+ $director.surname$ + $director.forname$ + $director.gender$ + $director.orcid$ +
+
+ $endfor$ + $endif$ +
+ + + $if(translator)$ + $for(translator)$ +
+
+ $translator.surname$ + $translator.forname$ +
+
+ $endfor$ + $endif$ +
+ + + $if(transcriber)$ + $for(transcriber)$ +
+
+ $transcriber.surname$ + $transcriber.forname$ +
+
+ $endfor$ + $endif$ + + + +
+ + $title_f$
+$if(subtitle_f)$ +$for(subtitle_f)$ + $subtitle_f$
+$endfor$ +$endif$ + + + $if(authors)$ + $for(authors)$ + $authors.forname$ $authors.surname$
+ $endfor$ + $endif$ + + + + $publisher$
+ $issnnum$ +
+ + +
+ + $journal$ + + $date$ + + + $if(dossier)$ + $for(dossier)$ + $dossier.title$ + $endfor$ + $endif$ + + + +
+ $if(abstract)$ + $for(abstract)$ +
$abstract.text_f$
+ $endfor$ + $endif$ +
+ +
+ + +$if(controlledKeywords)$ +
+$for(controlledKeywords)$ +$if(controlledKeywords.label)$ +
+ $controlledKeywords.label$ +$if(controlledKeywords.uriRameau)$ + $controlledKeywords.uriRameau$ +$endif$ +$if(controlledKeywords.idRameau)$ + $controlledKeywords.idRameau$ +$endif$ +$if(controlledKeywords.wikidata)$ + $controlledKeywords.wikidata$ +$endif$ +
+$endif$ +$endfor$ +
+$endif$ + +
+ + +
+ $if(keyword_fr_f)$ + $for(keyword_fr_f)$ + $keyword_fr_f$ + $endfor$ + $endif$ +
+
+ $if(keyword_en_f)$ + $for(keyword_en_f)$ + $keyword_en_f$ + $endfor$ + $endif$ +
+ + + +
+ $body$ + $for(include-after)$ + $include-after$ + $endfor$ +
+ + + + diff --git a/cgi-bin/exportArticleSP/templates-old/templateHtmlDcV2.html5 b/cgi-bin/exportArticleSP/templates-old/templateHtmlDcV2.html5 new file mode 100644 index 0000000..514c7e8 --- /dev/null +++ b/cgi-bin/exportArticleSP/templates-old/templateHtmlDcV2.html5 @@ -0,0 +1,455 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + $if(subtitle)$ + + $endif$ + + + + + + + + + + + + $if(url_article_sp)$ + + $endif$ + $if(url_article_sp)$ + + $endif$ + $if(issnnum)$ + + $endif$ + + + $if(director)$ + $for(director)$ + + + + $endfor$ + $endif$ + + + $if(authors)$ + $for(authors)$ + + + $endfor$ + $endif$ + + + $if(abstract)$ + $for(abstract)$ + + + $endfor$ + $endif$ + + + $if(keyword_fr)$ + + $endif$ + + $if(keyword_en)$ + + $endif$ + + $if(controlledKeywords)$ + $for(controlledKeywords)$ + $if(controlledKeywords.label)$ + + $endif$ + $endfor$ + $endif$ + + + $if(translator)$ + $for(translator)$ + + + $endfor$ + $endif$ + + + + $if(transcriber)$ + $for(transcriber)$ + + + $endfor$ + $endif$ + + + $if(redacteurDossier)$ + $for(redacteurDossier)$ + + + $endfor$ + $endif$ + + + $if(toc)$ + $for(toc)$ + + $endfor$ + $endif$ + + + + + + $for(authors)$ + + $endfor$ + + $if(subtitle)$ + + $endif$ + + + + + + + + $if(abstract)$ + $for(abstract)$ + + $endfor$ + $endif$ + + $if(keyword_fr)$ + + $endif$ + + $if(keyword_en)$ + + $endif$ + + + + + + + + + + + + + + + + + + + + + $if(url_article_sp)$ + + $endif$ + $if(issnnum)$ + + $endif$ + + + $if(subtitle)$ + + $endif$ + + + + + + + + + $for(authors)$ + + $endfor$ + + $if(translator)$ + $for(translator)$ + + $endfor$ + $endif$ + + $if(transcriber)$ + $for(transcriber)$ + + $endfor$ + $endif$ + + $if(abstract)$ + $for(abstract)$ + + $endfor$ + $endif$ + + $if(controlledKeywords)$ + $for(controlledKeywords)$ + $if(controlledKeywords.label)$ + + + $endif$ + $endfor$ + $endif$ + + + + + + + $if(title-prefix)$$title-prefix$ – $endif$$pagetitle$$if(subtitle)$ : $subtitle$$endif$ + + + + $if(quotes)$ + + $endif$ + $if(highlighting-css)$ + + $endif$ + $for(css)$ + + $endfor$ + $if(math)$ + $math$ + $endif$ + $for(header-includes)$ + $header-includes$ + $endfor$ + + + + + $for(include-before)$ + $include-before$ + $endfor$ + $if(toc)$ +
+ $toc$ +
+ $endif$ + + + +
+ + $if(authors)$ + $for(authors)$ +
+
+ $authors.surname$ + $authors.forname$ + $authors.orcid$ +
+
+ $endfor$ + $endif$ + + + $if(redacteurDossier)$ + $for(redacteurDossier)$ +
+
+ $redacteurDossier.surname$ + $redacteurDossier.forname$ + $redacteurDossier.gender$ + $redacteurDossier.orcid$ +
+
+ $endfor$ + $endif$ + + + $if(director)$ + $for(director)$ +
+
+ $director.surname$ + $director.forname$ + $director.gender$ + $director.orcid$ +
+
+ $endfor$ + $endif$ +
+ + + $if(translator)$ + $for(translator)$ +
+
+ $translator.surname$ + $translator.forname$ +
+
+ $endfor$ + $endif$ + + + + $if(transcriber)$ + $for(transcriber)$ +
+
+ $transcriber.surname$ + $transcriber.forname$ +
+
+ $endfor$ + $endif$ + + + +
+ + $title_f$
+$if(subtitle_f)$ +$for(subtitle_f)$ + $subtitle_f$
+$endfor$ +$endif$ + + + $if(authors)$ + $for(authors)$ + $authors.forname$ $authors.surname$
+ $endfor$ + $endif$ + + + + $publisher$
+ $issnnum$ +
+ + +
+ + $journal$ + + $date$ + + + $if(dossier)$ + $for(dossier)$ + $dossier.title$ + $endfor$ + $endif$ + + + +
+ $if(abstract)$ + $for(abstract)$ +
$abstract.text_f$
+ $endfor$ + $endif$ +
+ +
+ + +$if(controlledKeywords)$ +
+$for(controlledKeywords)$ +$if(controlledKeywords.label)$ +
+ $controlledKeywords.label$ +$if(controlledKeywords.uriRameau)$ + $controlledKeywords.uriRameau$ +$endif$ +$if(controlledKeywords.idRameau)$ + $controlledKeywords.idRameau$ +$endif$ +$if(controlledKeywords.wikidata)$ + $controlledKeywords.wikidata$ +$endif$ +
+$endif$ +$endfor$ +
+$endif$ + +
+ + +
+ $if(keyword_fr_f)$ + $for(keyword_fr_f)$ + $keyword_fr_f$ + $endfor$ + $endif$ +
+
+ $if(keyword_en_f)$ + $for(keyword_en_f)$ + $keyword_en_f$ + $endfor$ + $endif$ +
+ + + +
+ $body$ + $for(include-after)$ + $include-after$ + $endfor$ +
+ + + diff --git a/cgi-bin/exportArticleSP/templates-old/templateLaTeX.latex b/cgi-bin/exportArticleSP/templates-old/templateLaTeX.latex new file mode 100644 index 0000000..c66e6fd --- /dev/null +++ b/cgi-bin/exportArticleSP/templates-old/templateLaTeX.latex @@ -0,0 +1,380 @@ +\documentclass[12pt,$if(lang)$$babel-lang$,letterpaper,$endif$$for(classoption)$$classoption$$sep$,$endfor$]{article} + \usepackage[utf8]{inputenc} +\usepackage[french,english,spanish,italian,portuguese,german,ukrainian,arabic]{babel} +\usepackage{epigraph} +\usepackage{fancyhdr} +\pagestyle{fancy} +\usepackage[all]{nowidow} +\lhead{} +\chead{$title_f$} +\rhead{} +\lfoot{} +\cfoot{\thepage} +\rfoot{} + +\newcommand{\fr}{\selectlanguage{french}} +\newcommand{\en}{\selectlanguage{english}} +\newcommand{\es}{\selectlanguage{spanish}} +\newcommand{\pt}{\selectlanguage{portuguese}} +\newcommand{\de}{\selectlanguage{german}} +\newcommand{\uk}{\selectlanguage{ukrainian}} +\newcommand{\ita}{\selectlanguage{italian}} +\newcommand{\ar}{\selectlanguage{arabic}} +$if(fontfamily)$ +\usepackage[$for(fontfamilyoptions)$$fontfamilyoptions$$sep$,$endfor$]{$fontfamily$} +$else$ +\usepackage{lmodern} +$endif$ +$if(linestretch)$ +\usepackage{setspace} +\setstretch{$linestretch$} +$endif$ +\usepackage{amssymb,amsmath} +\usepackage{ifxetex,ifluatex} +\usepackage{fixltx2e} % provides \textsubscript +\ifnum 0\ifxetex 1\fi\ifluatex 1\fi=0 % if pdftex + \usepackage[$if(fontenc)$$fontenc$$else$T1$endif$]{fontenc} + +$if(euro)$ + \usepackage{eurosym} +$endif$ +\else % if luatex or xelatex +$if(mathspec)$ + \ifxetex + \usepackage{mathspec} + \else + \usepackage{unicode-math} + \fi +$else$ + \usepackage{unicode-math} +$endif$ + + + \defaultfontfeatures{Ligatures=TeX,Scale=MatchLowercase} +$for(fontfamilies)$ + \newfontfamily{$fontfamilies.name$}[$fontfamilies.options$]{$fontfamilies.font$} +$endfor$ +$if(euro)$ + \newcommand{\euro}{€} +$endif$ +$if(mainfont)$ + \setmainfont[$for(mainfontoptions)$$mainfontoptions$$sep$,$endfor$]{$mainfont$} +$endif$ +$if(sansfont)$ + \setsansfont[$for(sansfontoptions)$$sansfontoptions$$sep$,$endfor$]{$sansfont$} +$endif$ +$if(monofont)$ + \setmonofont[Mapping=tex-ansi$if(monofontoptions)$,$for(monofontoptions)$$monofontoptions$$sep$,$endfor$$endif$]{$monofont$} +$endif$ +$if(mathfont)$ +$if(mathspec)$ + \ifxetex + \setmathfont(Digits,Latin,Greek)[$for(mathfontoptions)$$mathfontoptions$$sep$,$endfor$]{$mathfont$} + \else + \setmathfont[$for(mathfontoptions)$$mathfontoptions$$sep$,$endfor$]{$mathfont$} + \fi +$else$ + \setmathfont[$for(mathfontoptions)$$mathfontoptions$$sep$,$endfor$]{$mathfont$} +$endif$ +$endif$ +$if(CJKmainfont)$ + \usepackage{xeCJK} + \setCJKmainfont[$for(CJKoptions)$$CJKoptions$$sep$,$endfor$]{$CJKmainfont$} +$endif$ +\fi +% use upquote if available, for straight quotes in verbatim environments +\IfFileExists{upquote.sty}{\usepackage{upquote}}{} +% use microtype if available +\IfFileExists{microtype.sty}{% +\usepackage[$for(microtypeoptions)$$microtypeoptions$$sep$,$endfor$]{microtype} +\UseMicrotypeSet[protrusion]{basicmath} % disable protrusion for tt fonts +}{} +\PassOptionsToPackage{hyphens}{url} % url is loaded by hyperref +$if(verbatim-in-note)$ +\usepackage{fancyvrb} +$endif$ +\usepackage[unicode=true]{hyperref} +$if(colorlinks)$ +\PassOptionsToPackage{usenames,dvipsnames}{color} % color is loaded by hyperref +$endif$ +\hypersetup{ +$if(title-meta)$ + pdftitle={$title-meta$}, +$endif$ +$if(author-meta)$ + pdfauthor={$author-meta$}, +$endif$ +$if(keywords)$ + pdfkeywords={$for(keywords)$$keywords$$sep$, $endfor$}, +$endif$ +$if(colorlinks)$ + colorlinks=true, + linkcolor=$if(linkcolor)$$linkcolor$$else$Maroon$endif$, + citecolor=$if(citecolor)$$citecolor$$else$Blue$endif$, + urlcolor=$if(urlcolor)$$urlcolor$$else$Blue$endif$, +$else$ + pdfborder={0 0 0}, +$endif$ + breaklinks=true} +\urlstyle{same} % don't use monospace font for urls +$if(verbatim-in-note)$ +\VerbatimFootnotes % allows verbatim text in footnotes +$endif$ +$if(geometry)$ +\usepackage[$for(geometry)$$geometry$$sep$,$endfor$]{geometry} +$endif$ + +$if(natbib)$ +\usepackage{natbib} +\bibliographystyle{$if(biblio-style)$$biblio-style$$else$plainnat$endif$} +$endif$ +$if(biblatex)$ +\usepackage[$if(biblio-style)$style=$biblio-style$,$endif$$for(biblatexoptions)$$biblatexoptions$$sep$,$endfor$]{biblatex} +$for(bibliography)$ +\addbibresource{$bibliography$} +$endfor$ +$endif$ +$if(listings)$ +\usepackage{listings} +$endif$ +$if(lhs)$ +\lstnewenvironment{code}{\lstset{language=Haskell,basicstyle=\small\ttfamily}}{} +$endif$ +$if(highlighting-macros)$ +$highlighting-macros$ +$endif$ +$if(tables)$ +\usepackage{longtable,booktabs} +% Fix footnotes in tables (requires footnote package) +\IfFileExists{footnote.sty}{\usepackage{footnote}\makesavenoteenv{long table}}{} +$endif$ + +\usepackage{graphicx,grffile} +\makeatletter +\def\maxwidth{\ifdim\Gin@nat@width>\linewidth\linewidth\else\Gin@nat@width\fi} +\def\maxheight{\ifdim\Gin@nat@height>\textheight\textheight\else\Gin@nat@height\fi} +\makeatother +% Scale images if necessary, so that they will not overflow the page +% margins by default, and it is still possible to overwrite the defaults +% using explicit options in \includegraphics[width, height, ...]{} +\setkeys{Gin}{width=\maxwidth,height=\maxheight,keepaspectratio} + +$if(links-as-notes)$ +% Make links footnotes instead of hotlinks: +\renewcommand{\href}[2]{#2\footnote{\url{#1}}} +$endif$ +$if(strikeout)$ +\usepackage[normalem]{ulem} +% avoid problems with \sout in headers with hyperref: +\pdfstringdefDisableCommands{\renewcommand{\sout}{}} +$endif$ +$if(indent)$ +$else$ +\IfFileExists{parskip.sty}{% +\usepackage{parskip} +}{% else +\setlength{\parindent}{0pt} +\setlength{\parskip}{6pt plus 2pt minus 1pt} +} +$endif$ +\setlength{\emergencystretch}{3em} % prevent overfull lines +\providecommand{\tightlist}{% + \setlength{\itemsep}{0pt}\setlength{\parskip}{0pt}} +$if(numbersections)$ +\setcounter{secnumdepth}{$if(secnumdepth)$$secnumdepth$$else$5$endif$} +$else$ +\setcounter{secnumdepth}{0} +$endif$ +$if(subparagraph)$ +$else$ +% Redefines (sub)paragraphs to behave more like sections +\ifx\paragraph\undefined\else +\let\oldparagraph\paragraph +\renewcommand{\paragraph}[1]{\oldparagraph{#1}\mbox{}} +\fi +\ifx\subparagraph\undefined\else +\let\oldsubparagraph\subparagraph +\renewcommand{\subparagraph}[1]{\oldsubparagraph{#1}\mbox{}} +\fi +$endif$ +$if(dir)$ +\ifxetex + % load bidi as late as possible as it modifies e.g. graphicx + $if(latex-dir-rtl)$ + \usepackage[RTLdocument]{bidi} + $else$ + \usepackage{bidi} + $endif$ +\fi +\ifnum 0\ifxetex 1\fi\ifluatex 1\fi=0 % if pdftex + \TeXXeTstate=1 + \newcommand{\RL}[1]{\beginR #1\endR} + \newcommand{\LR}[1]{\beginL #1\endL} + \newenvironment{RTL}{\beginR}{\endR} + \newenvironment{LTR}{\beginL}{\endL} +\fi +$endif$ + +% set default figure placement to htbp +\makeatletter +\def\fps@figure{htbp} +\makeatother + +$for(header-includes)$ +$header-includes$ +$endfor$ + +$if(title_f)$ +\title{$title_f$$if(thanks)$\thanks{$thanks$}$endif$} +$endif$ +$if(subtitle_f)$ +\providecommand{\subtitle}[1]{} +\subtitle{$subtitle_f$} +$endif$ +$if(authors)$ +\author{$for(authors)$$authors.forname$ $authors.surname$$sep$ \and $endfor$} +$endif$ +$if(institute)$ +\providecommand{\institute}[1]{} +\institute{$for(institute)$$institute$$sep$ \and $endfor$} +$endif$ +\date{} + +\begin{document} + +\thispagestyle{empty} +\begin{center} +\includegraphics[width=50mm]{media/logo.png}\\ +\vspace*{1cm} +\Huge $title_f$\\ +$if(subtitle_f)$ +\vspace*{0.5cm}\huge $subtitle_f$\\ +$endif$ +\vspace*{1cm} \LARGE $if(authors)$ +$for(authors)$$authors.forname$ $authors.surname$$sep$, $endfor$ +$endif$\\ +\normalsize\vspace*{1cm}Publié le $day$-$month$-$year$\\ +\vspace*{3cm} +\url{$url_article_sp$} +\end{center} + +\vspace*{\fill} +\begin{flushright} +\includegraphics[width=15mm]{media/crochets.png} +\end{flushright} + +\begin{center} +$rights$ +\end{center} + + +\newpage + +\thispagestyle{empty} + +$if(abstract)$ +$for(abstract)$ +\$abstract.lang$ + +\begin{abstract} + +$abstract.text_f$ +\end{abstract} + +$endfor$ +$endif$ + +\thispagestyle{empty} +$if(keyword_fr_f)$ +\textbf{Mots-clés}: +$keyword_fr_f$ +$endif$ + +\thispagestyle{empty} +$if(keyword_en_f)$ +\textbf{Keywords}: +$keyword_en_f$ +$endif$ + +\thispagestyle{empty} +$if(keyword_es_f)$ +\textbf{Keywords}: +$keyword_es_f$ +$endif$ + +\thispagestyle{empty} +$if(keyword_it_f)$ +\textbf{Keywords}: +$keyword_it_f$ +$endif$ + +\thispagestyle{empty} +$if(keyword_pt_f)$ +\textbf{Keywords}: +$keyword_pt_f$ +$endif$ + +\thispagestyle{empty} +$if(keyword_de_f)$ +\textbf{Keywords}: +$keyword_de_f$ +$endif$ + +\thispagestyle{empty} +$if(keyword_uk_f)$ +\textbf{Keywords}: +$keyword_uk_f$ +$endif$ + +\thispagestyle{empty} +$if(keyword_ar_f)$ +\textbf{Keywords}: +$keyword_ar_f$ +$endif$ + + +$for(include-before)$ +$include-before$ + +$endfor$ + +$if(toc)$ +\newpage + +\thispagestyle{empty} +\$lang$ +\tableofcontents +$endif$ + +$if(lot)$ +\listoftables +$endif$ +$if(lof)$ +\listoffigures +$endif$ +\newpage \thispagestyle{empty} +\maketitle +$body$ + +$if(natbib)$ +$if(bibliography)$ +$if(biblio-title)$ +$if(book-class)$ +\renewcommand\bibname{$biblio-title$} +$else$ +\renewcommand\refname{$biblio-title$} +$endif$ +$endif$ +\bibliography{$for(bibliography)$$bibliography$$sep$,$endfor$} + +$endif$ +$endif$ +$if(biblatex)$ +\printbibliography$if(biblio-title)$[title=$biblio-title$]$endif$ + +$endif$ +$for(include-after)$ +$include-after$ + +$endfor$ +\end{document} diff --git a/cgi-bin/exportBook/templates b/cgi-bin/exportBook/templates new file mode 160000 index 0000000..07dfef3 --- /dev/null +++ b/cgi-bin/exportBook/templates @@ -0,0 +1 @@ +Subproject commit 07dfef3cf5c0455fd3ef1c35ded6790eb5a63fb4 diff --git a/html/exportsenspublic.html b/html/exportsenspublic.html new file mode 100644 index 0000000..b1ab9f4 --- /dev/null +++ b/html/exportsenspublic.html @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + + + +

Stylo export

+
+ Identifiant de l'article:
+ Version:
+ + Processor:
+
+
+ + +
+ + + + diff --git a/html/genericexport.html b/html/genericexport.html new file mode 100644 index 0000000..2948370 --- /dev/null +++ b/html/genericexport.html @@ -0,0 +1,56 @@ + + + + + + + + + + + + + + + + + + + + + + +

Stylo export

+
+ Identifiant de l'article:
+ Version:
+ + Format: + +
+Bibliographical style: + + +
+ Processor:
+
+
+ + +
+ + + + diff --git a/html/index.html b/html/index.html index f7641fa..3e3f04c 100644 --- a/html/index.html +++ b/html/index.html @@ -23,17 +23,8 @@

Stylo export

-
- Identifiant de l'article:
- Version:
- - Processor:
-
-
- - -
- +

Stylo generic export

+

Stylo export Sens public