VERSION=211123
 pwd > pwd.txt
 if cat pwd.txt | grep ~/Annexer
 then Workdir=~/Annexer
 elif cat pwd.txt | grep ~/Add_appendix
 then Workdir=~/Add_appendix
 else echo "Workind directory not found"
 exit -1
 fi
 rm pwd.txt
 source $Workdir/vars/installdir.var
 if test -z $Mandir
 then Mandir=$Installdir/man
 fi
 if test -z $Sbindir
 then Sbindir=$Installdir/sbin
 fi
 if test -z $Testsdir
 then Testsdir=$Workdir/tests
 fi
 echo "Manuals directories = $Mandir"
 echo "Sbindir = $Sbindir"
 echo "Testsdir = $Testsdir"
 cd $Testsdir/02-manuels
 if (ls -al *.1)
 then
 echo "*.1 found in $Testsdir/02-manuels"; cp -u *.1 archives/.
 else "*.1 not found, exit -1"
 exit -1
 fi
 mkdir -p de en es fr fr.UTF-8 ko
 mkdir -p man1
 mkdir -p de/man1
 mkdir -p en/man1
 mkdir -p es/man1
 mkdir -p fr/man1
 mkdir -p fr.UTF-8/man1
 mkdir -p ko/man1
 ls -1 *.1 > man1.list
 while read line
 do
 case $line in
 (*_de.1) echo "line: $line"; gzip -c $line > de/man1/$line.gz; man2html -r de/man1/$line.gz > de/man1/*.html; man de/man1/$line.gz > de/man1/$line.txt ;;
 (*_en.1) echo "line: $line"; gzip -c $line > en/man1/$line.gz; man2html -r en/man1/$line.gz > en/man1/$line.html; man en/man1/$line.gz > en/man1/$line.txt ;;
 (*_es.1) echo "line: $line"; gzip -c $line > es/man1/$line.gz; man2html -r es/man1/$line.gz > es/$line.html; man es/man1/$line.gz > es/man1/$line.txt ;;
 (*_fr.1) echo "line: $line"; gzip -c $line > fr/man1/$line.gz; man2html -r fr/man1/$line.gz > fr/man1/$line.html; man fr/man1/$line.gz > fr/man1/$line.txt ;;
 (*_fr.UTF-8.1) echo "line: $line"; gzip -c $line > fr.UTF-8/man1/$line.gz; man2html -r fr.UTF-8/man1/$line.gz > fr.UTF-8/$line.html; man fr.UTF-8/man1/$line.gz > fr.UTF-8/man1/$line.txt ;;
 (*_ko.1) echo "line: $line"; gzip -c $line > ko/man1/$line.gz; man2html -r ko/man1/$line.gz > ko/$line.html; man ko/man1/$line.gz > ko/man1/$line.txt ;;
 esac 
 done < man1.list
 rm man1html.list
 ls -R man1/*_en.1.html > man1html.list
 ls -R de/man1/*_de.1.html » man1html.list
 ls -R en/man1/*_en.1.html » man1html.list
 ls -R es/man1/*_es.1.html » man1html.list
 ls -R fr/man1/*_fr.1.html » man1html.list
 ls -R fr.UTF-8/man1/*_fr.UTF-8.1.html » man1html.list
 ls -R ko/man1/*_ko.1.html » man1html.list 
 if test -s man1html.list
 then
 while read newline
 do
 echo -n "newline : "
 if echo $newline | grep "_en"; then echo $newline | sed "s/_en.1//g" > newname.txt;fi
 if echo $newline | grep "_de"; then echo $newline | sed "s/_de.1//g" > newname.txt;fi
 if echo $newline | grep "_es"; then echo $newline | sed "s/_es.1//g" > newname.txt;fi
 if echo $newline | grep "_fr"; then echo $newline | sed "s/_fr.1//g" > newname.txt;fi
 if echo $newline | grep "_fr.UTF-8"; then echo $newline | sed "s/_fr.UTF-8.1//g" > newname.txt;fi
 if echo $newline | grep "_ko"; then echo $newline | sed "s/_ko.1//g" > newname.txt;fi
 read Newname < newname.txt
 echo "newname : $Newname"
 mv $newline $Newname
 done <man1html.list
 fi
 rm man1txt.list
 ls -R man1/*_en.1.txt > man1txt.list
 ls -R de/man1/*_de.1.txt » man1txt.list
 ls -R en/man1/*_en.1.txt » man1txt.list
 ls -R es/man1/*_es.1.txt » man1txt.list
 ls -R fr/man1/*_fr.1.txt » man1txt.list
 ls -R fr.UTF-8/man1/*_fr.UTF-8.1.txt » man1txt.list
 ls -R ko/man1/*_ko.1.txt » man1txt.list
 if test -s man1txt.list
 then
 while read newline
 do
 echo -n "newline : "
 if echo $newline | grep "_en"; then echo $newline | sed "s/_en.1//g" > newname.txt;fi
 if echo $newline | grep "_de"; then echo $newline | sed "s/_de.1//g" > newname.txt;fi
 if echo $newline | grep "_es"; then echo $newline | sed "s/_es.1//g" > newname.txt;fi
 if echo $newline | grep "_fr"; then echo $newline | sed "s/_fr.1//g" > newname.txt;fi
 if echo $newline | grep "_fr.UTF-8"; then echo $newline | sed "s/_fr.UTF-8.1//g" > newname.txt;fi
 if echo $newline | grep "_ko"; then echo $newline | sed "s/_ko.1//g" > newname.txt;fi
 read Newname < newname.txt
 echo "newname : $Newname"
 mv $newline $Newname
 done <man1txt.list
 fi
 rm *.list newname*
 exit 0

Auto-éditer un wikilivre/Annexer (Version internationalisée)/makeman annex.sh

# Compresser
 gzip -c annex_fr.1 > annex_fr.1.gz
 # Fichier: En lecture seule
 chmod 444 annex_fr.1.gz
 # Installation
 echo "Installation du manuel français"
 if [ -d "/usr/share/man/fr.UTF-8/man1" ]; \
 then sudo cp -f annex_fr.1.gz /usr/share/man/fr.UTF-8/man1/annex.1.gz
 elif [ -d "/usr/share/man/fr/" ]; \
 then sudo cp -f annex_fr.1.gz /usr/share/man/fr/man1/annex.1.gz
 fi

Auto-éditer un wikilivre/Annexer (Version internationalisée)/install datasfiles.sh