projects
/
projects.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
Merge branch 'master' of http://wagnertech.de/git/projects
[projects.git]
/
sh
/
sysd2sysv
1
#!/bin/bash
2
set -e
3
4
if [ $# -ne 2 ]
5
then
6
echo "usage: sysd2sysv <command> <deamon>"
7
exit 1
8
fi
9
10
if [ ! -f /etc/init.d/$2 ]
11
cp /etc/sysd2sysv/$2 /etc/init.d/
12
fi
13
14
if [ $1 = "enable" ]
15
then
16
update-rc.d $2 defaults 100
17
elif [ $1 = "disable" ]
18
then
19
update-rc.d -f $2 remove
20
else
21
/etc/init.d/$2 $1
22
fi
23
24