README FOR loop_n_log --------------------- loop_n_log is a simple tool that runs a command on an infinite loop, with a specified wait period between each run, logging any output to syslog. Unlike cron, command runs can be separated by seconds instead of minutes. It also lets you log to syslog from commands that know nothing of it. In some ways, this turns a command into a poor man's daemon process. INSTALLATION ------------ In the Makefile, set INST_ROOT to wherever you want the software installed. You may also need to change the INSTALL command, depending on the location and version of "install" on your system. Then run "make install". USE --- "loop_n_log -h" will print out a usage statement. Basically, the usage is: loop_n_log -t timer [-f facility] [-l level] command The timer is a wait period between runs of the specified command, in seconds. The facility and level determine how the output is sent to syslog, and defaults to user.notice. You don't need to quote the command argument. PLATFORMS --------- loop_n_log has been written for portability to most UNIX systems. It's been tested on the following platforms: - Darwin/Mac OS X - versions 6.x/10.2.x - Linux - Red Hat, versions 6.x through 7.0 - Cobalt Linux CHANGES ------- You're not required by the license to submit changes back to the source, but I'd appreciate portability improvements or enhancements of general applicability. You can email new versions or contextual diffs ("diff -c old_file new_file") to . Some things to keep in mind if you do this: - Formatting - I use tabs for indentation, and sometimes to align code segments for readability. Please do the same. - Please don't use NotePad or some other Windows editor to make changes. Or if you do, get rid of the DOS linefeeds before submitting changes. - Please try to follow the formatting conventions established in the existing code. - Readability - Usually, I will trade off efficiency (of running time or of development time) in favor of readability. - Insert meaningful comments where appropriate. - Portability - All shell scripts are Bourne-compatible. I won't use shell- specific constructs from bash, ksh, etc. - Don't use OS-specific features, pathnames, etc., unless they're guarded by code checking the OS version, or they're in user-settable variables toward the top of the script. CONTRIBUTORS ------------ Leon Towns-von Stauber Enjoy! Copyright (c) 2000-2003. All rights reserved. See the LICENSE file distributed with this code for restrictions on its use and further distribution. Original distribution available at .