-->

Previous | Table of Contents | Next

Page 84

_$ Forbid the use of $ in identifiers. This is required for ANSI conformance. gcc automatically supplies this option to the preprocessor if you specify _ansi, but gcc doesn't recognize the _$ option itself; to use it without the other effects of _ansi, you must call the preprocessor directly.

SEE ALSO

cpp entry in info; The C Preprocessor, Richard M. Stallman.

gcc(1); gcc entry in info; Using and Porting GNU CC (for version 2.0), Richard M. Stallman.

COPYING

Copyright " 1991, 1992, 1993 Free Software Foundation, Inc. Permission is granted to make and distribute verbatim copies of this manual provided the copyright notice and this permission notice are preserved on all copies.

Permission is granted to copy and distribute modified versions of this manual under the conditions for verbatim copying, provided that the entire resulting derived work is distributed under the terms of a permission notice identical to this one.

Permission is granted to copy and distribute translations of this manual into another language, under the above conditions for modified versions, except that this permission notice may be included in translations approved by the Free Software Foundation instead of in the original English.

GNU Tools, 30 April 1993

crontab

crontab—Manipulate per-user crontabs (Dillon's Cron)

SYNOPSIS

crontab file [-u user] Replace crontab from file

crontab - [-u user] Replace crontab from stdin
crontab -l [user] List crontab for user
crontab -e [user] Edit crontab for user
crontab -d [user] Delete crontab for user
crontab -c dir Specify crontab directory

DESCRIPTION

crontab manipulates the crontab for a particular user. Only the superuser may specify a different user and/or crontab directory. Generally, the -e option is used to edit your crontab. crontab will use /usr/bin/vi or the editor specified by your VISUAL environment variable to edit the crontab.

Unlike other crond/crontabs, this crontab does not try to do everything under the sun. Frankly, a shell script is much more able to manipulate the environment than cron, and I see no particular reason to use the user's shell (from his password entry) to run cron commands when this requires special casing of nonuser crontabs, such as those for UUCP. When a crontab command is run, this crontab runs it with /bin/sh and sets up only three environment variables: USER, HOME, and SHELL.

crond automatically detects changes in the time. Reverse-indexed time changes less then an hour old will NOT rerun crontab commands already issued in the recovered period. Forward-indexed changes less then an hour into the future will issue missed commands exactly once. Changes greater then an hour into the past or future cause crond to resynchronize and not issue missed commands. No attempt will be made to issue commands lost due to a reboot, and commands are not reissued if the previously issued command is still running. For example, if you have a crontab command sleep 70 that you wish to run once a minute, cron will only be able to issue the command once every two minutes. If you do not like this feature, you can run your commands in the background with an &.

Page 85

The crontab format is roughly similar to that used by vixiecron, but without complex features. Individual fields may contain a time, a time range, a time range with a skip factor, a symbolic range for the day of week and month in year, and additional subranges delimited with commas. Blank lines in the crontab or lines that begin with a hash (#) are ignored. If you specify both a day in the month and a day of week, the result is effectively ORd; the crontab entry will be run on the specified day of week and on the specified day in the month.


# MIN HOUR DAY MONTH DAYOFWEEK COMMAND

# at 6:10 a.m. every day

10 6 ***date



# every two hours at the top of the hour

0 */2 ***date



# every two hours from 11p.m. to 7a.m., and at 8a.m.

0 23-7/2,8 ***date



# at 11:00 a.m. on the 4th and on every mon, tue, wed

0 11 4 * mon-wed date



# 4:00 a.m. on january 1st

0 4 1 jan *date



# once an hour, all output appended to log file

0 4 1 jan *date>>/var/log/messages 2>&1

The command portion of the line is run with /bin/sh _c <command>, and may therefore contain any valid Bourne shell command. A common practice is to run your command with exec to keep the process table uncluttered. It is also common to redirect output to a log file. If you do not, and the command generates output on stdout or stderr, the result will be mailed to the user in question. If you use this mechanism for special users, such as UUCP, you may want to create an alias for the user to direct the mail to someone else, such as root or postmaster.

Internally, this cron uses a quick indexing system to reduce CPU overhead when looking for commands to execute. Several hundred crontabs with several thousand entries can be handled without using noticeable CPU resources.

BUGS

Ought to be able to have several crontab files for any given user, as an organizational tool.

AUTHOR

Matthew Dillon (dillon@apollo.west.oic.com)

1 May 1994

csplit

csplit—Split a file into sections determined by context lines

SYNOPSIS


csplit [_sqkz] [_f prefix] [_b suffix] [_n digits] [—prefix=prefix]

[—suffix_format=suffix] [—digits=digits] [—quiet] [—silent]

[—keep-files] [—elide_empty_files] [—help] [—version]

file pattern...

DESCRIPTION

This manual page documents the GNU version of csplit. csplit creates zero or more output files containing sections of the given input file, or the standard input if the name _ is given. By default, csplit prints the number of bytes written to each output file after it has been created.

Previous | Table of Contents | Next