Changeset 23
- Timestamp:
- 09/28/07 12:27:10 (17 years ago)
- Location:
- trunk
- Files:
-
- 5 edited
- 1 moved
Legend:
- Unmodified
- Added
- Removed
-
trunk/before.sh
- Property svn:keywords set to Id
r22 r23 2 2 # 3 3 # module : 4 # préparation du répertoire d'accueil de bibnemomaf 5 # - arborescence; 6 # - copie des images; 7 # - copie des feuilles de styles; 8 # - copie des .ht* (pas testable sur file:++); 4 # preparation of temporary (before deployement) of superbib results directory 5 # - tree; 6 # - copy of constant images copie des images; 7 # - copy of CSS style sheet; 9 8 # - etc. 10 9 # 11 # original location :12 # /usr/home/fplod/incas/bibnemo/src/bibnemomaf/avant.sh sur aedon.locean-ipsl.upmc.fr13 #14 10 # update : 11 # $Id$ 12 # fplod 2007-09-28T08:43:10Z aedon.locean-ipsl.upmc.fr (Darwin) 13 # parametrisation and translation 15 14 # fplod 2007-03-30T09:55:49Z aedon.locean-ipsl.upmc.fr (Darwin) 16 15 # création 17 16 # 18 # ++ simu paramètre19 produit=bibnemomaf20 lang=en21 17 # 22 DIRSRC=. 23 DIRWWW=/tmp/bibopa/ 18 set -o posix 19 command=$(basename ${0} .sh) 20 log_date=$(date -u +"%Y-%m-%dT%H:%M:%SZ") 21 log=/tmp/${command}.${log_date} 22 # 23 usage=" Usage : ${command} -p product -s dirsrc -w dirwww -l lang -mono|-multi" 24 # 25 minargcount=9 26 echo " narg ${#}" 27 if [ ${#} -lt ${minargcount} ] 28 then 29 echo "eee : not enought arguments" 30 echo "${usage}" 31 exit 1 32 fi 33 # 34 while [ ! -z "${1}" ] 35 do 36 case ${1} in 37 -p) # product 38 product=${2} 39 shift 40 ;; 41 -s) # dirsrc 42 dirsrc=${2} 43 shift 44 ;; 45 -w) # dirwww 46 dirwww=${2} 47 shift 48 ;; 49 -l) # lang 50 lang=${2} 51 shift 52 ;; 53 -mono ) # monolingual 54 monolingual=1 55 ;; 56 -multi ) # multiingual 57 monolingual=0 58 ;; 59 esac 60 shift # next flag 61 done 62 # 63 set -u 24 64 # 25 65 # destruction of previous installation 26 /bin/rm -r ${ DIRWWW}/ 2> /dev/null66 /bin/rm -r ${dirwww}/ 2> /dev/null 27 67 # 28 68 # building of directories 29 mkdir -p ${DIRWWW}/images/ 30 mkdir -p ${DIRWWW}/php/ 31 mkdir -p ${DIRWWW}/${lang}/one/ 32 mkdir -p ${DIRWWW}/${lang}/many/${produit}03/ 33 mkdir -p ${DIRWWW}/${lang}/many/${produit}04/ 69 mkdir -p ${dirwww}/images/ 70 mkdir -p ${dirwww}/php/ 71 if [ ${monolingual} = 0 ] 72 then 73 mkdir -p ${dirwww}/${lang}/one/ 74 mkdir -p ${dirwww}/${lang}/many/${product}03/ 75 mkdir -p ${dirwww}/${lang}/many/${product}04/ 76 else 77 mkdir -p ${dirwww}/one/ 78 mkdir -p ${dirwww}/many/${product}03/ 79 mkdir -p ${dirwww}/many/${product}04/ 80 fi 34 81 # 35 list_php="${ DIRSRC}/phpversion.php ${DIRSRC}/server.php ${DIRSRC}/timestamp.php"82 list_php="${dirsrc}/phpversion.php ${dirsrc}/server.php ${dirsrc}/timestamp.php" 36 83 for file_php in ${list_php} 37 84 do 38 cp ${file_php} ${ DIRWWW}/php/85 cp ${file_php} ${dirwww}/php/ 39 86 done 40 87 # 41 mkdir -p ${DIRWWW}/${lang}//images/ # ++ parce que un niveau de plus que d'haibitude dans les chunck 42 cp ${DIRSRC}/images/* ${DIRWWW}/images/ 43 cp ${DIRSRC}/images/* ${DIRWWW}/en/images/ # ++ parce que un niveau de plus que d'habitude dans les chunck 88 if [ ${monolingual} = 0 ] 89 then 90 mkdir -p ${dirwww}/${lang}//images/ # ++ parce que un niveau de plus que d'haibitude dans les chunck 91 cp ${dirsrc}/images/* ${dirwww}/images/ 92 cp ${dirsrc}/images/* ${dirwww}/${lang}/images/ # ++ parce que un niveau de plus que d'habitude dans les chunck 93 else 94 mkdir -p ${dirwww}/images/ # ++ parce que un niveau de plus que d'haibitude dans les chunck 95 cp ${dirsrc}/images/* ${dirwww}/images/ 96 fi 44 97 # 45 98 # copy of CSS 46 cp ${ DIRSRC}/*.css ${DIRWWW}/47 cp ${ DIRSRC}/*.css ${DIRWWW}/en/ # ++ parce que un niveau de plus que d'haibitude dans les chunck99 cp ${dirsrc}/*.css ${dirwww}/ 100 cp ${dirsrc}/*.css ${dirwww}/${lang}/ # ++ parce que un niveau de plus que d'haibitude dans les chunck 48 101 # 49 # modification du temps de création des répetoires pour que le50 # makefile déclenche les générations de html51 find ${ DIRWWW}/ -type d -exec touch -t 199912310000 {} \;102 # modification of directory time in order to trigger the generation of HTML 103 # files 104 find ${dirwww}/ -type d -exec touch -t 199912310000 {} \; 52 105 # 53 # fin106 # end 54 107 exit 0 -
trunk/checklink.sh
r2 r23 15 15 set -o posix 16 16 command=$(basename ${0}) 17 # 17 # 18 18 # ++ simu paramètre 19 19 DIRWWW=/usr/temp/${LOGNAME}/public_html/bibnemomaf/ … … 21 21 checklinkopt="--summary --recursive" 22 22 # 23 # is checklink available 23 # is checklink available 24 24 type checklink 1> /dev/null 2>&1 25 25 checklink_status=${?} -
trunk/install.sh
- Property svn:keywords set to Id
r14 r23 2 2 # 3 3 # module : 4 # installation des pages bibnemomaf dans DIRFINAL* donné en argument 5 # à partir des fichiers produits ou copiés ou liés sous DIRWWW 6 # donné en argument 4 # publication (rsync) of dirwww content on dirpublish given in argument 7 5 # 8 # nb : !!! attention utilisation du compte fplod@aedon.lodyc.jussieu.fr 9 # 10 # source : 11 # /usr/home/fplod/incas/bibnemo/src/bibnemomaf/install.sh sur aedon.locean-ipsl.upmc.fr 6 # If the host of publication is cerbere.locean-ipsl.upmc.fr, update_web is 7 # launched. 12 8 # 13 9 # update 10 # $Id$ 11 # fplod 2007-09-28T09:30:43Z aedon.locean-ipsl.upmc.fr (Darwin) 12 # parametrisation and translation 14 13 # smasson 2007-06-07T16:43:42Z arete.locean-ipsl.upmc.fr (Darwin) 15 14 # can give the answer with input parameters 16 15 # fplod 2007-04-26T11:51:42Z aedon.locean-ipsl.upmc.fr (Darwin) 17 16 # 18 # ++ simu paramètre 19 DIRFINALLOCEAN=smasson@arete.locean-ipsl.upmc.fr:Sites/bibnemomaf/ 20 DIRWWW=/tmp/bibopa/ 17 set -o posix 18 command=$(basename ${0} .sh) 19 log_date=$(date -u +"%Y-%m-%dT%H:%M:%SZ") 20 log=/tmp/${command}.${log_date} 21 # 22 usage=" Usage : ${command} -w dirwww -p dirpublish" 23 # 24 minargcount=4 25 echo " narg ${#}" 26 if [ ${#} -lt ${minargcount} ] 27 then 28 echo "eee : not enought arguments" 29 echo "${usage}" 30 exit 1 31 fi 32 # 33 while [ ! -z "${1}" ] 34 do 35 case ${1} in 36 -w) 37 dirwww=${2} 38 shift 39 ;; 40 -p) 41 dirpublish=${2} 42 shift 43 ;; 44 esac 45 shift # next flag 46 done 47 # 48 set -u 49 # 50 # ++ check directories 21 51 # 22 52 answer=${1:-" "} … … 25 55 ;; 26 56 *) 27 echo "Do you want to install on ${ DIRFINALLOCEAN} (y|[n]) ?"28 read answer 57 echo "Do you want to install on ${dirpublish} (y|[n]) ?" 58 read answer 29 59 ;; 30 60 esac 31 61 case ${answer} in 32 62 y|Y) 33 # copy of ${DIRWWW} on $DIRFINALLOCEAN 34 echo "iii : update of ${DIRFINALLOCEAN}" 35 rsync -av -e ssh ${DIRWWW}/ ${DIRFINALLOCEAN} 36 # pas sur aedon ssh fplod@cerbere.lodyc.jussieu.fr /usr/local_linux/bin/update_web 63 # copy of ${dirwww} on $dirpublish 64 echo "iii : update of ${dirpublish}" 65 rsync -av -e ssh ${dirwww}/ ${dirpublish} 66 # detect if in dirpublish following this pattern [USER@]HOST:SRC, HOST 67 # is cerbere.locean-ipsl.upmc.fr. If so, update_web is launched 68 userhost=${dirpublish%%:*} 69 host=${userhost##*@} 70 if [ "${host}" = "cerbere.locean-ipsl.upmc.fr" ] 71 then 72 ssh ${userhost} /usr/local_linux/bin/update_web 73 fi 37 74 ;; 38 75 *) 39 echo "no update of ${DIRFINALLOCEAN}" 40 ;; 41 esac 42 # 43 # ++ simu paramètre 44 DIRFINALLOCEAN=opatlod@cerbere.locean-ipsl.upmc.fr:NEMO/general/biblio_new/ 45 # 46 answer=${2:-" "} 47 case ${answer} in 48 y|Y|n|N) 49 ;; 50 *) 51 echo "Do you want to install on ${DIRFINALLOCEAN} (y|[n]) ?" 52 read answer 53 ;; 54 esac 55 case ${answer} in 56 y|Y) 57 # copy of ${DIRWWW} on $DIRFINALLOCEAN 58 echo "iii : update of ${DIRFINALLOCEAN}" 59 rsync -av -e ssh ${DIRWWW}/ ${DIRFINALLOCEAN} 60 ssh opatlod@cerbere.lodyc.jussieu.fr /usr/local_linux/bin/update_web 61 ;; 62 *) 63 echo "no update of ${DIRFINALLOCEAN}" 76 echo "no update of ${dirpublish}" 64 77 ;; 65 78 esac -
trunk/mailtousernemo.sh
r4 r23 312 312 # 313 313 # ++ parce que je ne sais pas dire où est la dtd dans la commande xmllint 314 cp usernemo.dtd /tmp/ 314 cp usernemo.dtd /tmp/ 315 315 xmllint --noout --valid ${xmloutputfull} 1>> ${log} 2>> ${log} 316 316 status=${?} -
trunk/makefile
r21 r23 9 9 # ++ les dépendences ne marchent pas bien 10 10 # ++ la génération de pdf ne marchent pas bien sans doute à cause des images top 11 # fplod 2007-09-28T08:56:17Z aedon.locean-ipsl.upmc.fr (Darwin) 12 # add before and install targets 11 13 # fplod 2007-06-06T10:23:19Z aedon.locean-ipsl.upmc.fr (Darwin) 12 14 # change hard coded DIRBASE … … 40 42 /tmp/bibopa/ 41 43 44 # here are some examples of DIRPUBLISH, the first on for Seb on his Mac, 45 # the second one for me (Françoise) on mine 46 # the third for me (Françoise) on my home page http://www.locean-ipsl.upmc.fr/~fplod/superbibdemo/ 47 # 48 # the real one for NEMO is opatlod@cerbere.locean-ispl.upmc.fr:NEMO/general/biblio_new/ 49 # 50 # comment all of them and define your own 51 # 52 #DIRPUBLISH = \ 53 #smasson@arete.locean-ipsl.upmc.fr:Sites/bibnemomaf/ 54 55 #DIRPUBLISH = \ 56 #fplod@aedon.locean-ipsl.upmc.fr:Sites/superbibdemo/ 57 58 DIRPUBLISH = \ 59 fplod@cerbere.locean-ipsl.upmc.fr:./WWW/superbibdemo/ 60 42 61 MAKEDATE = \ 43 62 `date -u +"%Y-%m-%dT%H:%M:%SZ"` … … 74 93 75 94 help : 95 @echo "Define in the makefile localisations of :" 96 @echo " - sources (DIRSRC) where you \"svn checkout\" superbib" 97 @echo " - temporary Web pages (DIRWWW), where you can check links before publication" 98 @echo "- published Web pages (DIRPUBLISH)" 99 @echo "" 76 100 @echo "Prepare output directories :" 77 @echo "$ ./avant.sh" 101 @echo "$ make before" 102 @echo "" 78 103 @echo "identify bibliography databank; for example :" 79 104 @echo "$ ln -sf data/biball.xml bibrefnemo.xml" 80 105 @echo "check for duplicate DOI; for example :" 81 106 @echo "$ ./twindoi.sh -i bibrefnemo.xml -t xml" 107 @echo "" 82 108 @echo "identify usernemo databank; for example :" 83 109 @echo "$ ln -sf data/usernemo.xml usernemo.xml" 84 110 @echo "$ ln -sf data/usernemo.dtd usernemo.dtd" 111 @echo "" 85 112 @echo "Following commands are available to build outputs :" 86 113 @echo "$ make html_en" 87 114 @echo "$ make pdf_en" 88 115 @echo "Last step = installation" 89 @echo "$ ./install.sh"116 @echo "$ make install" 90 117 @echo " " 91 118 @echo "if you move this product to an other place, " 92 @echo "change DIRWWW,DIRBASE,DIRTMP in makefile" 93 @echo "change DIRSRC,DIRWWW in ./avant.sh" 94 @echo "change DIRFINALLOCEAN,DIRWWW in ./install.sh" 119 @echo "change parameters in the call sequence of ./before.sh and ./install.sh" 120 @echo "and in the call sequence of in ./install.sh" 121 @echo "in this makefile" 122 123 before : 124 ./before.sh -p $(PRODUIT) -s $(DIRSRC) -w $(DIRWWW) -multi -l en 125 126 install : 127 ./install.sh -w $(DIRWWW) -p $(DIRPUBLISH) 95 128 96 129 clean : … … 131 164 $(DIRWWW)/en/one/$(PRODUIT2).html 132 165 133 pdf_en : \166 pdf_en : ./\ 134 167 $(DIRTMP)/$(PRODUIT)01.pdf \ 135 168 $(DIRTMP)/$(PRODUIT)02.pdf -
trunk/twindoi.sh
r20 r23 15 15 # (xml vs txt) did not give any alert and check inside 16 16 # xml comments 17 # $ ./twindoi.sh -i data/biball.xml -t raw 17 # $ ./twindoi.sh -i data/biball.xml -t raw 18 18 # $Id$ 19 19 # smasson 2007-06-20T16:11:47Z … … 33 33 do 34 34 case ${1} in 35 -i) # filein 35 -i) # filein 36 36 filein=${2} 37 37 shift 38 38 ;; 39 -t) # type 39 -t) # type 40 40 type=${2} 41 41 shift … … 50 50 set -u 51 51 # 52 # check for filein 52 # check for filein 53 53 if [ ! -f ${filein} ] 54 54 then … … 64 64 filexml=${filein} 65 65 ;; 66 *) 66 *) 67 67 echo "eee : type should be raw or xml" 68 68 exit 1 … … 95 95 if [ ${nl} -eq 0 ] 96 96 then 97 echo "www : no DOI found in ${filein}" 97 echo "www : no DOI found in ${filein}" 98 98 rm /tmp/doilist.txt 2> /dev/null 99 99 exit 1 100 fi 100 fi 101 101 n=1 102 102 while [ ${n} -lt ${nl} ]
Note: See TracChangeset
for help on using the changeset viewer.