Last change
on this file since 113 was
92,
checked in by g7moreau, 14 years ago
|
- Change /etc/klask.conf to /etc/klask/klask.conf
|
File size:
795 bytes
|
Line | |
---|
1 | #!/bin/bash |
---|
2 | # |
---|
3 | # 2011/03/30 gabriel - create |
---|
4 | |
---|
5 | |
---|
6 | check_conf() { |
---|
7 | if [ ! -r /etc/klask/klask.conf ] |
---|
8 | then |
---|
9 | echo "No config file for klask /etc/klask.conf" |
---|
10 | exit 1 |
---|
11 | fi |
---|
12 | if [ ! -r /etc/klask/push-web.conf ] |
---|
13 | then |
---|
14 | echo "No config file for klask-push-web /etc/klask/push-web.conf" |
---|
15 | exit 1 |
---|
16 | fi |
---|
17 | if [ ! -x /usr/sbin/klask ] |
---|
18 | then |
---|
19 | echo "No main program klask" |
---|
20 | exit 1 |
---|
21 | fi |
---|
22 | if [ ! -x /usr/lib/klask/push-web ] |
---|
23 | then |
---|
24 | echo "No program klask push-web" |
---|
25 | exit 1 |
---|
26 | fi |
---|
27 | } |
---|
28 | |
---|
29 | case "$1" in |
---|
30 | update) |
---|
31 | check_conf |
---|
32 | /usr/sbin/klask updatedb |
---|
33 | /usr/lib/klask/push-web |
---|
34 | ;; |
---|
35 | |
---|
36 | clean) |
---|
37 | check_conf |
---|
38 | /usr/sbin/klask cleandb |
---|
39 | /usr/lib/klask/push-web |
---|
40 | ;; |
---|
41 | |
---|
42 | *) |
---|
43 | echo "Usage: $0 {update|clean}" |
---|
44 | exit 1 |
---|
45 | ;; |
---|
46 | esac |
---|
47 | |
---|
48 | exit 0 |
---|
Note: See
TracBrowser
for help on using the repository browser.