4 # this script reads the working directory, and changes documentation files which
5 # reference digest to refer to edigest it is passed the location of the working directory
6 # as an argument. this allows the program digest to be placed into the pkg/bin directory
7 # without overwriting the pkgtool program digest
10 #function to switch directories based on a passed variable
18 html) cd ${ABSDIR}/${DIR}
22 text) cd ${ABSDIR}/text
27 *) echo "ERROR: bad directory given to digestchange script, directory was: $DIR"
38 for HFILE in *html ; do
40 sed -e 's|digest\.html|edigest\.html|g' \
41 -e 's/>digest/>edigest/g' \
42 -e 's/^digest/edigest/g' \
43 -e 's|EMBOSS: digest|EMBOSS: edigest|g' \
44 -e 's|session with digest|session with edigest|g' \
45 -e 's|opsd_human.digest|opsd_human.edigest|g' \
46 -e 's|Program: digest|Program: edigest|g' \
47 -e 's|% digest|% edigest|g' \
48 -e 's|digest[ ]\{10,13\}Protein|edigest Protein|g' \
49 ${HFILE} > ${HFILE}.new ;
51 mv ${HFILE}.new ${HFILE}
52 echo "digestchange modified ${HFILE}"
58 for HMFILE in Makefile* ; do
60 sed -e 's| digest\.html| edigest\.html|g' ${HMFILE} > ${HMFILE}.new ;
62 mv ${HMFILE}.new ${HMFILE}
63 echo "digestchange modified ${HMFILE}"
73 for TFILE in *txt ; do
77 sed -e 's|session with digest|session with edigest|g' \
78 -e 's|opsd_human.digest|opsd_human.edigest|g' \
79 -e 's/rogram. digest/rogram edigest/g' \
80 -e 's|% digest|% edigest|g' \
81 -e 's/ \{30,40\}digest/ edigest/g' \
82 -e 's/digest \{6,13\}Protein/edigest Protein/g' \
83 -e 's/digest( )\{1,3\}Protein/edigest Protein/g' \
84 -e 's| digest finds| edigest finds|g' \
85 ${TFILE} > ${TFILE}.new ;
87 mv ${TFILE}.new ${TFILE}
89 echo "digestchange modified ${TFILE}"
94 for TMFILE in Makefile* ; do
96 sed -e 's| digest\.txt| edigest\.txt|g' ${TMFILE} > ${TMFILE}.new ;
98 mv ${TMFILE}.new ${TMFILE}
100 echo "digestchange modified ${TMFILE}"
107 # Main body of the script
111 BASEDIR=${WRKINGDIR}/doc/programs
122 #emboss/acd/Makefile.am
123 #emboss/acd/Makefile.in
124 #emboss/acd/digest.acd