blob: ce0a32daf2e2134a72549ffc330bfc72e54b0d81 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
|
#!/bin/sh
_varname='G4NEUTRONXSDATA'
_packagename='geant4-neutronxsdata'
_foldername='G4NEUTRONXS'
_dataversion=1.4
_add() {
echo "export ${_varname}=/usr/share/${_packagename}/${_foldername}${_dataversion}" >> /etc/profile.d/geant4.sh
echo "setenv ${_varname} /usr/share/${_packagename}/${_foldername}${_dataversion}" >> /etc/profile.d/geant4.csh
}
_remove() {
sed -i "/${_varname}/d" /etc/profile.d/geant4.sh
sed -i "/${_varname}/d" /etc/profile.d/geant4.csh
}
pre_install() {
_remove
}
post_install() {
_add
}
pre_upgrade() {
_remove
}
post_upgrade() {
_add
}
pre_remove() {
_remove
}
post_remove() {
_remove
}
|