repo.or.cz
/
aur-mirror.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
updated on Thu Jan 26 16:09:46 UTC 2012
[aur-mirror.git]
/
deskopt
/
deskopt.sh
blob
9e2ad75417b46451ab8441a094ffa477e55ff591
1
#! /bin/sh
2
3
.
/
etc
/
rc.conf
4
.
/
etc
/
rc.d
/
functions
5
6
deskopt_start
() {
7
deskopt
-c
/
etc
/
deskopt.conf ||
return
1
8
}
9
10
deskopt_stop
() {
11
deskopt
-q
12
sleep
1
s
13
if
[
$?
-gt
0
];
then
14
kill -9
$PID
&> /
dev
/
null ||
return
1
15
fi
16
}
17
18
case
$1
in
19
start
)
20
stat_busy
"Starting DeskOpt"
21
deskopt_start
22
if
[
$?
-gt
0
];
then
23
stat_fail
24
else
25
add_daemon deskoptd
26
stat_done
27
fi
28
;;
29
stop
)
30
stat_busy
"Stopping DeskOpt"
31
deskopt_stop
32
if
[
$?
-gt
0
];
then
33
stat_fail
34
else
35
rm_daemon deskoptd
36
stat_done
37
fi
38
;;
39
restart
)
40
$0
stop
41
$0
start
42
;;
43
*)
44
echo
"Usage:
$0
{start|stop|restart}"
45
;;
46
esac