Subversion Repositories livecd

Rev

Rev 123 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 123 Rev 125
Line 6... Line 6...
6
#
6
#
7
# Urs Beyerle, PSI
7
# Urs Beyerle, PSI
8
#
8
#
9
###############################################################
9
###############################################################
10
 
10
 
11
# source livecd.conf
-
 
12
. livecd.conf
-
 
13
 
-
 
14
###############################################################
-
 
15
 
-
 
16
function usage() {
11
function usage() {
17
 
12
 
18
   ## Usage
13
   ## Usage
19
   # ----------------------------------------------------------
14
   # ----------------------------------------------------------
20
 
15
 
Line 44... Line 39...
44
            usage; exit;;
39
            usage; exit;;
45
    esac
40
    esac
46
 
41
 
47
done
42
done
48
 
43
 
49
 
-
 
50
###############################################################
-
 
51
 
-
 
52
### check if I run inside my directory
44
### check if I run inside my directory
53
if [ ! -x $( basename $0 ) ]; then
45
if [ ! -x $( basename $0 ) ]; then
54
    echo "Please run $( basename $0 ) within its directory"
46
    echo "Please run $( basename $0 ) within its directory"
55
    exit 1
47
    exit 1
56
fi
48
fi
57
 
49
 
-
 
50
# source livecd.conf
-
 
51
. livecd.conf
-
 
52
 
58
LIVECD_DIR=$( pwd )
53
LIVECD_DIR=$( pwd )
59
 
54
 
60
### restore /etc/rc.d/rc.sysinit
55
### restore /etc/rc.d/rc.sysinit
61
cp /etc/rc.d/rc.sysinit.ori /etc/rc.d/rc.sysinit
56
cp /etc/rc.d/rc.sysinit.ori /etc/rc.d/rc.sysinit
62
 
57
 
Line 70... Line 65...
70
 
65
 
71
### restore /etc/resolv.conf
66
### restore /etc/resolv.conf
72
mv -f /etc/resolv.conf.ori /etc/resolv.conf
67
mv -f /etc/resolv.conf.ori /etc/resolv.conf
73
 
68
 
74
### move /etc/yum.repos.d, it will interfere with our yum.conf.psi
69
### move /etc/yum.repos.d, it will interfere with our yum.conf.psi
-
 
70
if [ -e /etc/yum.conf.psi ]; then
75
if [ -d /etc/yum.repos.d ]; then
71
    if [ -d /etc/yum.repos.d ]; then
76
    rm -rf /etc/yum.repos.d.ori
72
	rm -rf /etc/yum.repos.d.ori
77
    mv -f /etc/yum.repos.d /etc/yum.repos.d.ori
73
	mv -f /etc/yum.repos.d /etc/yum.repos.d.ori
-
 
74
    fi
78
fi
75
fi
79
 
76
 
80
### restore folders from /mini
77
### restore folders from /mini
81
echo "restore folders from /mini ..."
78
echo "restore folders from /mini ..."
82
mv /mini/usr/share/doc/* /usr/share/doc/ 2>/dev/null
79
mv /mini/usr/share/doc/* /usr/share/doc/ 2>/dev/null