diff options
author | Mike Barcroft <mike@FreeBSD.org> | 2002-01-22 03:04:15 +0000 |
---|---|---|
committer | Mike Barcroft <mike@FreeBSD.org> | 2002-01-22 03:04:15 +0000 |
commit | e1bc822ebee9dbef5dc4ded81887db2ee03ff813 (patch) | |
tree | 54b4584c7bcd89e231f6627203d63a3d0434c876 /usr.bin/at | |
parent | 500c14f6af86c4782fe2627af04fe9c546ded5e3 (diff) | |
download | src-test2-e1bc822ebee9dbef5dc4ded81887db2ee03ff813.tar.gz src-test2-e1bc822ebee9dbef5dc4ded81887db2ee03ff813.zip |
Notes
Diffstat (limited to 'usr.bin/at')
-rw-r--r-- | usr.bin/at/at.c | 22 | ||||
-rw-r--r-- | usr.bin/at/at.man | 33 | ||||
-rw-r--r-- | usr.bin/at/panic.c | 14 |
3 files changed, 26 insertions, 43 deletions
diff --git a/usr.bin/at/at.c b/usr.bin/at/at.c index 84198d9db0fc..5d4b642c38e3 100644 --- a/usr.bin/at/at.c +++ b/usr.bin/at/at.c @@ -673,8 +673,7 @@ main(int argc, char **argv) char *pgm; int program = AT; /* our default program */ - const char *options = "q:f:t:rmvldbVc"; /* default options for at */ - int disp_version = 0; + const char *options = "q:f:t:rmvldbc"; /* default options for at */ time_t timer; timer = -1; @@ -693,15 +692,15 @@ main(int argc, char **argv) */ if (strcmp(pgm, "atq") == 0) { program = ATQ; - options = "q:vV"; + options = "q:v"; } else if (strcmp(pgm, "atrm") == 0) { program = ATRM; - options = "V"; + options = ""; } else if (strcmp(pgm, "batch") == 0) { program = BATCH; - options = "f:q:mvV"; + options = "f:q:mv"; } /* process whatever options we can process @@ -741,7 +740,7 @@ main(int argc, char **argv) usage(); program = ATRM; - options = "V"; + options = ""; break; case 't': @@ -755,7 +754,7 @@ main(int argc, char **argv) usage(); program = ATQ; - options = "q:vV"; + options = "q:v"; break; case 'b': @@ -763,11 +762,7 @@ main(int argc, char **argv) usage(); program = BATCH; - options = "f:q:mvV"; - break; - - case 'V': - disp_version = 1; + options = "f:q:mv"; break; case 'c': @@ -782,9 +777,6 @@ main(int argc, char **argv) /* end of options eating */ - if (disp_version) - fprintf(stderr, "%s version " VERSION "\n", namep); - /* select our program */ if(!check_permission()) diff --git a/usr.bin/at/at.man b/usr.bin/at/at.man index 9abdbd20b046..19b79d1a5a27 100644 --- a/usr.bin/at/at.man +++ b/usr.bin/at/at.man @@ -10,36 +10,29 @@ .Nd queue, examine or delete jobs for later execution .Sh SYNOPSIS .Nm at -.Op Fl V .Op Fl q Ar queue .Op Fl f Ar file .Op Fl mldbv .Ar time .Nm at -.Op Fl V .Op Fl q Ar queue .Op Fl f Ar file .Op Fl mldbv .Fl t Ar [[CC]YY]MMDDhhmm[.SS] .Nm at -.Op Fl V .Fl c Ar job Op Ar job ... .Nm at -.Op Fl V .Fl r Ar job Op Ar job ... .Pp .Nm atq -.Op Fl V .Op Fl q Ar queue .Op Fl v .Pp .Nm atrm -.Op Fl V .Ar job .Op Ar job ... .Pp .Nm batch -.Op Fl V .Op Fl q Ar queue .Op Fl f Ar file .Op Fl mv @@ -75,18 +68,18 @@ or .Ar HH:MM to run a job at a specific time of day. (If that time is already past, the next day is assumed.) -You may also specify +As an alternative, the following keywords may be specified: .Em midnight , .Em noon , or .Em teatime (4pm) -and you can have a time-of-day suffixed with +and time-of-day may be suffixed with .Em AM or .Em PM for running in the morning or the evening. -You can also say what day the job will be run, +The day on which the job is to be run may also be specified by giving a date in the form .Ar \%month-name day with an optional @@ -100,7 +93,7 @@ or giving a date of the forms .Ar MMDDYY . The specification of a date must follow the specification of the time of day. -You can also give times like +Time can also be specified as: .Op Em now .Em + Ar count \%time-units , where the time-units can be @@ -111,18 +104,18 @@ where the time-units can be .Em months or .Em years -and you can tell +and .Nm -to run the job today by suffixing the time with +may be told to run the job today by suffixing the time with .Em today and to run the job tomorrow by suffixing the time with .Em tomorrow . .Pp -For example, to run a job at 4pm three days from now, you would do +For example, to run a job at 4pm three days from now, use .Nm at Ar 4pm + 3 days , -to run a job at 10:00am on July 31, you would do +to run a job at 10:00am on July 31, use .Nm at Ar 10am Jul 31 -and to run a job at 1am tomorrow, you would do +and to run a job at 1am tomorrow, use .Nm at Ar 1am tomorrow . .Pp The @@ -191,8 +184,6 @@ If neither exists, only the superuser is allowed use of This is the default configuration. .Sh OPTIONS .Bl -tag -width indent -.It Fl V -Print the version number to standard error. .It Fl q Ar queue Use the specified queue. A queue designation consists of a single letter; valid queue designations @@ -317,9 +308,9 @@ and .Nm batch as presently implemented are not suitable when users are competing for resources. -If this is the case for your site, you might want to consider another -batch system, such as -.Em nqs . +If this is the case, another batch system such as +.Em nqs +may be more suitable. .Pp Specifying a date past 2038 may not work on some systems. .Sh AUTHORS diff --git a/usr.bin/at/panic.c b/usr.bin/at/panic.c index 99cf512ee067..34c527a9e2e4 100644 --- a/usr.bin/at/panic.c +++ b/usr.bin/at/panic.c @@ -79,12 +79,12 @@ void usage(void) { /* Print usage and exit. */ - fprintf(stderr, "usage: at [-V] [-q x] [-f file] [-m] time\n" - " at [-V] -c job [job ...]\n" - " at [-V] [-f file] -t [[CC]YY]MMDDhhmm[.SS]\n" - " at [-V] -r job [job ...]\n" - " atq [-V] [-q x] [-v]\n" - " atrm [-V] job [job ...]\n" - " batch [-V] [-f file] [-m]\n"); + fprintf(stderr, "usage: at [-q x] [-f file] [-m] time\n" + " at -c job [job ...]\n" + " at [-f file] -t [[CC]YY]MMDDhhmm[.SS]\n" + " at -r job [job ...]\n" + " atq [-q x] [-v]\n" + " atrm job [job ...]\n" + " batch [-f file] [-m]\n"); exit(EXIT_FAILURE); } |