[ Index ] |
PHP Cross Reference of Unnamed Project |
[Summary view] [Print] [Text view]
1 #! /bin/bash 2 # postinst script for smbedu 3 # 4 # see: dh_installdeb(1) 5 6 set -e 7 8 # summary of how this script can be called: 9 # * <postinst> `configure' <most-recently-configured-version> 10 # * <old-postinst> `abort-upgrade' <new version> 11 # * <conflictor's-postinst> `abort-remove' `in-favour' <package> 12 # <new-version> 13 # * <deconfigured's-postinst> `abort-deconfigure' `in-favour' 14 # <failed-install-package> <version> `removing' 15 # <conflicting-package> <version> 16 # for details, see /usr/doc/packaging-manual/ 17 # 18 # quoting from the policy: 19 # Any necessary prompting should almost always be confined to the 20 # post-installation script, and should be protected with a conditional 21 # so that unnecessary prompting doesn't happen if a package's 22 # installation fails and the `postinst' is called with `abort-upgrade', 23 # `abort-remove' or `abort-deconfigure'. 24 case "$1" in 25 configure) 26 case `cat /etc/debian_version` in 27 4.0) 28 install_script="install_se3_etch.sh" 29 ;; 30 5.0*) 31 install_script="install_se3_lenny.sh" 32 ;; 33 6.0*) 34 install_script="install_se3_squeeze.sh" 35 ;; 36 7.*) 37 install_script="install_se3_wheezy.sh" 38 ;; 39 *) 40 echo "Version Debian inconnue" 41 exit 1 42 ;; 43 esac 44 if [ ! -e /etc/sudoers ]; then 45 cp /etc/sudoers.se3 /etc/sudoers 46 chmod 440 /etc/sudoers 47 fi 48 cd /var/cache/se3_install/ 49 if [ -f /etc/SeConfig.ph ]; then 50 echo "Voulez-vous faire la mise a jour de SambaEdu3 ? O/n" 51 read -t 20 rep || rep="o" 52 if [ "$rep" = "n" -o "$rep" = "N" ]; then 53 echo "Voulez-vous Reinstaller SambaEdu3 ? o/n" 54 read rep 55 #[ "$rep" = "o" ] && ./$install_script 56 [ "$rep" = "o" -o "$rep" = "O" ] && ./$install_script 57 else 58 ./maj_se.sh 59 fi 60 61 /usr/share/se3/scripts/permse3 62 echo "Instanciation en cours..." 63 /usr/share/se3/sbin/instance_se3.sh 64 /usr/share/se3/sbin/create_adminse3.sh 65 66 67 else 68 ./$install_script 69 fi 70 ;; 71 72 *) 73 echo "postinst called with unknown argument \`$1'" >&2 74 exit 0 75 ;; 76 esac 77 78 # dh_installdeb will replace this with shell code automatically 79 # generated by other debhelper scripts. 80 81 # Automatically added by dh_installdocs 82 if [ "$1" = "configure" ]; then 83 if [ -d /usr/doc -a ! -e /usr/doc/se3 -a -d /usr/share/doc/se3 ]; then 84 ln -sf /var/cache/se3_install/doc /usr/doc/se3 85 ln -sf /var/cache/se3_install/doc /usr/share/doc/se3 86 fi 87 fi 88 # End automatically added section 89 90 91 exit 0
title
Description
Body
title
Description
Body
title
Description
Body
title
Body
Generated: Tue Mar 17 22:47:18 2015 | Cross-referenced by PHPXref 0.7.1 |