source: trunk/checklink.sh @ 2

Last change on this file since 2 was 2, checked in by smasson, 17 years ago

initial import

File size: 1.5 KB
Line 
1#! /bin/sh
2#
3# module :
4# vérification des liens bibnemomaf pré et post-installation
5# cf. install.sh
6#
7# source :
8# /usr/home/fplod/incas/bibnemo/src/bibnemomaf/checklink.sh sur aedon.locean-ipsl.upmc.fr
9#
10# mise à jour :
11# fplod 2007-04-04T14:09:14Z aedon.locean-ipsl.upmc.fr (Darwin)
12# création
13#
14set -u
15set -o posix
16command=$(basename ${0})
17
18# ++ simu paramètre
19DIRWWW=/usr/temp/${LOGNAME}/public_html/bibnemomaf/
20#
21checklinkopt="--summary --recursive"
22#
23# is checklink available
24type checklink 1> /dev/null 2>&1
25checklink_status=${?}
26if [ ${checklink_status} -ne 0 ]
27then
28   echo "${command} : eee : checklink unavailable"
29   exit 1
30fi
31#
32echo " "
33fverif=${DIRWWW}/en/one/bibnemomaf00.html
34nfverif=www_en_one_bibnemomaf00.html
35echo " Do you want to check ${fverif} (y|[n]) ?"
36answer=" "
37read answer
38case ${answer} in
39 Y|y)
40 log=/tmp/checklink${nfverif}.log
41 err=/tmp/checklink${nfverif}.err
42 echo "verif de ${fverif}"
43 checklink \
44 ${checklinkopt} \
45 ${fverif} \
46 1> ${log} 2> ${err}
47 echo "iii : log in ${log}"
48 ;;
49 *)
50 echo "no check ${fverif}"
51 ;;
52esac
53#
54echo " "
55fverif=${DIRWWW}/en/one/bibnemomaf01.html
56nfverif=www_en_one_bibnemomaf01.html
57echo " Do you want to check ${fverif} (y|[n]) ?"
58answer=" "
59read answer
60case ${answer} in
61 Y|y)
62 log=/tmp/checklink${nfverif}.log
63 err=/tmp/checklink${nfverif}.err
64 echo "verif de ${fverif}"
65 checklink \
66 ${checklinkopt} \
67 ${fverif} \
68 1> ${log} 2> ${err}
69 echo "iii : log in ${log}"
70 ;;
71 *)
72 echo "no check ${fverif}"
73 ;;
74esac
75#
76exit
Note: See TracBrowser for help on using the repository browser.