From 5c2d1bf09d73bfd7597c0bc5dab2219f2b174804 Mon Sep 17 00:00:00 2001 From: Waldemar Brodkorb Date: Mon, 19 Sep 2011 14:33:02 +0200 Subject: update to latest svn version --- package/motion/files/motion.init | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 package/motion/files/motion.init (limited to 'package/motion/files/motion.init') diff --git a/package/motion/files/motion.init b/package/motion/files/motion.init new file mode 100644 index 000000000..1c8b7e705 --- /dev/null +++ b/package/motion/files/motion.init @@ -0,0 +1,27 @@ +#!/bin/sh +#PKG motion +#INIT 80 +. /etc/rc.conf + +case $1 in +autostop) ;; +autostart) + test x"${motion:-NO}" = x"NO" && exit 0 + exec sh $0 start + ;; +start) + [ -f /etc/motion.conf ] || exit + /usr/bin/motion + ;; +stop) + kill $(pgrep -f /usr/bin/motion) + ;; +restart) + sh $0 stop + sh $0 start + ;; +*) + echo "Usage: $0 {start | stop | restart}" + ;; +esac +exit $? -- cgit v1.2.3