From fc658d15d40c7795e9460948e889706d1a9554ab Mon Sep 17 00:00:00 2001 From: "David F. Skoll" Date: Sat, 11 Aug 2007 22:22:12 -0400 Subject: [PATCH] Fix typos. Document -y option. --- man/remind.1 | 13 ++++++++++++- scripts/tkremind | 2 +- src/custom.h | 2 +- src/custom.h.in | 4 ++-- src/queue.c | 2 +- 5 files changed, 17 insertions(+), 6 deletions(-) diff --git a/man/remind.1 b/man/remind.1 index cbe3ea42..5da490fb 100644 --- a/man/remind.1 +++ b/man/remind.1 @@ -217,6 +217,10 @@ case, it only changes the environment variables as described above. It does not change the effective uid or gid. .RE .TP +\fB-y\fR +Causes \fBRemind\fR to synthesize a tag for any reminder that lacks a +TAG clause. +.TP \fB\-i\fR\fIvar\fR\fB=\fR\fIexpr\fR Sets the value of the specified \fIvar\fR to \fIexpr\fR, and \fBpreserves\fR \fIvar\fR. \fIExpr\fR can be any valid \fBRemind\fR expression. See the @@ -849,7 +853,14 @@ tags; you should \fInot\fR use the \fBTAG\fR keyword yourself, or your script will interact badly with back-ends. .PP The \fBTAG\fR keyword is followed by a tag consisting of up to -32 characters. +48 characters. +.PP +If you supply the \fB\-y\fR option to \fBRemind\fR, then any +reminder that lacks a \fBTAG\fR will have one synthesized. The +synthesized tag consists of the characters "__syn__" followed +by the hexadecimal representation of the MD5 sum of the REM +command line. This lets you give a more-or-less unique identifier +to each distinct REM command. .PP The \fBDURATION\fR keyword makes sense only for timed reminders; it specifies the duration of an event. Currently, this is not diff --git a/scripts/tkremind b/scripts/tkremind index c76d6c8d..ba63f748 100755 --- a/scripts/tkremind +++ b/scripts/tkremind @@ -155,7 +155,7 @@ proc Initialize {} { global DayNames argc argv CommandLine ReminderFile AppendFile Remind PSCmd global MondayFirst - set CommandLine "|$Remind -itkremind=1 -p -l" + set CommandLine "|$Remind -itkremind=1 -p -y -l" set PSCmd "$Remind -p -l" set i 0 while {$i < $argc} { diff --git a/src/custom.h b/src/custom.h index b3ed3384..e4177461 100644 --- a/src/custom.h +++ b/src/custom.h @@ -204,7 +204,7 @@ /*---------------------------------------------------------------------*/ #define TAG_LEN 48 -#define PASSTHRU_LEN 48 +#define PASSTHRU_LEN 32 #define PSBEGIN "# rem2ps begin" #define PSEND "# rem2ps end" diff --git a/src/custom.h.in b/src/custom.h.in index a59b3320..e4177461 100644 --- a/src/custom.h.in +++ b/src/custom.h.in @@ -202,9 +202,9 @@ /*---------------------------------------------------------------------*/ /* TAG_LEN: The maximum length of tags. Don't change it */ /*---------------------------------------------------------------------*/ -#define TAG_LEN 32 +#define TAG_LEN 48 -#define PASSTHRU_LEN 24 +#define PASSTHRU_LEN 32 #define PSBEGIN "# rem2ps begin" #define PSEND "# rem2ps end" diff --git a/src/queue.c b/src/queue.c index 02c7da1f..ab51790e 100644 --- a/src/queue.c +++ b/src/queue.c @@ -95,7 +95,7 @@ int QueueReminder(ParsePtr p, Trigger *trig, qelem->ntrig = 0; strcpy(qelem->sched, sched); strcpy(qelem->tag, trig->tag); - if (!qelem->tag && SynthesizeTags) { + if (! *qelem->tag && SynthesizeTags) { SynthesizeTag(qelem->tag); } QueueHead = qelem;