bin/electric_eye in electric_eye-0.0.3 vs bin/electric_eye in electric_eye-0.0.5
- old
+ new
@@ -26,10 +26,14 @@
@configEye.set_path(options[:path])
elsif options[:s] # Start recording
@record.start
elsif options[:k] # Stop recordings
@record.stop
+ elsif options[:t]
+ @configEye.set_threshold(options[:threshold])
+ else
+ puts opts.help
end
exit 0
end
@@ -39,13 +43,14 @@
# Accept flags via:
on("-a", "--add", "Add a camera")
on("-r", "--remove", "Remove a camera")
on("-l", "--list", "List cameras")
- on("-d", "--duration SECONDS", "Set recording duration in seconds")
+ on("-d", "--duration SECONDS", "Set recording duration in seconds (default: 600)")
on("-p", "--path DIR", "Set recordings path")
on("-s", "--start", "Start recordings")
on("-k", "--stop", "Stop recordings")
+ on("-t", "--threshold LEVEL", "Set threshold for motion detection (default: 2)")
# Arguments
arg :camera, :optional
arg :url, :optional