Compare commits

...

12 Commits

Author SHA1 Message Date
Dianne Skoll
21d28ebfc3 Bump version to 05.04.01. 2025-06-15 09:29:36 -04:00
Dianne Skoll
b300422cdb Update release notes. 2025-06-15 09:27:57 -04:00
Dianne Skoll
37e09f4671 Fix bug in processing UNTIL clause.
Bug found by Ian! D. Allen.
2025-06-15 09:15:48 -04:00
Dianne Skoll
b6e53341c8 Add utils/add-html-anchors.rem standard file. 2025-06-10 14:26:51 -04:00
Dianne Skoll
896fcf1d7f Yet more wording. 2025-06-07 23:05:34 -04:00
Dianne Skoll
72155329f2 Tweak wording, again. 2025-06-07 23:04:47 -04:00
Dianne Skoll
36c7db510a Tweak wording. 2025-06-07 23:03:46 -04:00
Dianne Skoll
d4aa73747d Add some comments. 2025-06-07 22:45:02 -04:00
Dianne Skoll
3ed657b708 Add a couple more SPECIALs to test. 2025-06-07 22:40:55 -04:00
Dianne Skoll
0441c0263b Make rem2pdf *ACTUALLY* support "special colour" 2025-06-07 22:38:19 -04:00
Dianne Skoll
c40d4ee672 Fix misleading comment. 2025-06-07 22:13:08 -04:00
Dianne Skoll
96f2d6537a Update the main README.md file. 2025-06-06 21:54:49 -04:00
12 changed files with 118 additions and 34 deletions

28
NOTE-ABOUT-AI.txt Normal file
View File

@@ -0,0 +1,28 @@
Some Notes about AI/LLMs/GPTs/etc.
==================================
1) No part of Remind was written using AI of any type.
I certify that all of the C, Perl and Tcl code in Remind was written
by a human being. I certify that all code in .rem files other than
ones under include/holidays was written by a human being. The code
under include/holidays was derived from the Python "holidays" library
and I have no direct knowledge of the provenance of that library,
though I suspect it's entirely or almost entirely human-written.
I certify that all of the man pages and other documentation that
ship with Remind were human-written and not generated with any sort
of AI.
2) No AI-generated patches or other sorts of contributions to Remind
will be accepted.
3) Remind's source code may not be used to train an AI model,
including an LLM model, unless all of the output of said model is
released under the GNU General Public License, version 2. If you use
any of Remind's source code to train your model, then anything that
the model produces is a derived product of Remind and must be licensed
under the same terms as Remind.
--
Dianne Skoll

View File

@@ -55,6 +55,19 @@ edit custom.h on your behalf:
`wish ./build.tk`
## Usage
Remind is a large and complex program. You can read the full manual page
with:
`man remind`
after installation. However, the man page is long and detailed and is
more of a reference than an introduction. You can get an overview
with a [slide deck](https://dianne.skoll.ca/projects/remind/download/remind-oclug.pdf)
I made a while back. There's also a (long) [YouTube video](https://www.youtube.com/watch?v=0SNgvsDvx7M) that serves as an
introduction to Remind.
---
Contact info: dianne@skoll.ca

18
configure vendored
View File

@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.71 for remind 05.04.00.
# Generated by GNU Autoconf 2.71 for remind 05.04.01.
#
#
# Copyright (C) 1992-1996, 1998-2017, 2020-2021 Free Software Foundation,
@@ -608,8 +608,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='remind'
PACKAGE_TARNAME='remind'
PACKAGE_VERSION='05.04.00'
PACKAGE_STRING='remind 05.04.00'
PACKAGE_VERSION='05.04.01'
PACKAGE_STRING='remind 05.04.01'
PACKAGE_BUGREPORT=''
PACKAGE_URL='https://dianne.skoll.ca/projects/remind/'
@@ -1265,7 +1265,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
\`configure' configures remind 05.04.00 to adapt to many kinds of systems.
\`configure' configures remind 05.04.01 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1327,7 +1327,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
short | recursive ) echo "Configuration of remind 05.04.00:";;
short | recursive ) echo "Configuration of remind 05.04.01:";;
esac
cat <<\_ACEOF
@@ -1415,7 +1415,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
remind configure 05.04.00
remind configure 05.04.01
generated by GNU Autoconf 2.71
Copyright (C) 2021 Free Software Foundation, Inc.
@@ -1865,7 +1865,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by remind $as_me 05.04.00, which was
It was created by remind $as_me 05.04.01, which was
generated by GNU Autoconf 2.71. Invocation command line was
$ $0$ac_configure_args_raw
@@ -4710,7 +4710,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
This file was extended by remind $as_me 05.04.00, which was
This file was extended by remind $as_me 05.04.01, which was
generated by GNU Autoconf 2.71. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -4775,7 +4775,7 @@ ac_cs_config_escaped=`printf "%s\n" "$ac_cs_config" | sed "s/^ //; s/'/'\\\\\\\\
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_config='$ac_cs_config_escaped'
ac_cs_version="\\
remind config.status 05.04.00
remind config.status 05.04.01
configured by $0, generated by GNU Autoconf 2.71,
with options \\"\$ac_cs_config\\"

View File

@@ -1,6 +1,6 @@
dnl Process this file with autoconf to produce a configure script.
AC_INIT(remind, 05.04.00, , , https://dianne.skoll.ca/projects/remind/)
AC_INIT(remind, 05.04.01, , , https://dianne.skoll.ca/projects/remind/)
AC_CONFIG_SRCDIR([src/queue.c])
cat <<'EOF'

View File

@@ -1,5 +1,19 @@
CHANGES TO REMIND
* VERSION 5.4 Patch 1 - 2025-06-15
- MAJOR BUG FIX: remind: In some circumstances, a REM command could
yield a trigger date after its UNTIL date, rather than recognizing it
as having expired. This has been fixed. Bug found by Ian! D. Allen.
- BUG FIX: rem2pdf: Support the COLOUR special (as well as COLOR).
- MINOR IMPROVEMENT: Add include/utils/add-html-anchors.rem. You can
INCLUDE this file to get HTML anchors added to every calendar day
by rem2html.
- DOCUMENTATION: Add NOTE-ABOUT-AI.txt
* VERSION 5.4 Patch 0 - 2025-06-03
- MAJOR IMPROVEMENT: remind: Track which expressions and variables

View File

@@ -0,0 +1,5 @@
# Add HTML anchors to each day box.
# This adds anchors: <a id="YYYY-MM-DD" name="YYYY-MM-DD"></a>
# to each calendar box in an HTML calendar.
REM SPECIAL HTML <a id="[$T]" name="[$T]"></a>

View File

@@ -265,6 +265,7 @@ while(1) {
}
my ($obj, $err) = Remind::PDF->create_from_stream(*STDIN,
{color => 1,
colour => 1,
shade => 1,
moon => 1,
pango => 1,

View File

@@ -1,6 +1,6 @@
/***************************************************************/
/* */
/* HASHTAB_STATS.C */
/* HASHTAB.C */
/* */
/* Implementation of hash table. */
/* */

View File

@@ -310,15 +310,15 @@ static int GetNextTriggerDate(Trigger *trig, int start, int *err, int *nextstart
{
int simple, mod, omit;
/* First: Have we passed the UNTIL date? */
/* First: Have we passed the UNTIL date? */
if (trig->until != NO_UNTIL &&
trig->until < start) {
trig->expired = 1;
return -1; /* expired */
}
/* Next: If it's an "AFTER"-type skip, back up
until we're at the start of a block of holidays */
/* Next: If it's an "AFTER"-type skip, back up
until we're at the start of a block of holidays */
if (trig->skip == AFTER_SKIP) {
int iter = 0;
while (iter++ <= MaxSatIter) {
@@ -339,16 +339,16 @@ static int GetNextTriggerDate(Trigger *trig, int start, int *err, int *nextstart
}
}
/* Find the next simple trigger */
/* Find the next simple trigger */
simple = NextSimpleTrig(start, trig, err);
/* Problems? */
/* Problems? */
if (*err || (simple == -1)) return -1;
/* Suggested starting point for next attempt */
/* Suggested starting point for next attempt */
*nextstart = simple+1;
/* If there's a BACK, back up... */
/* If there's a BACK, back up... */
if (trig->back != NO_BACK) {
mod = trig->back;
if (mod < 0) {
@@ -376,7 +376,7 @@ static int GetNextTriggerDate(Trigger *trig, int start, int *err, int *nextstart
}
}
/* If there's a REP, calculate the next occurrence */
/* If there's a REP, calculate the next occurrence */
if (trig->rep != NO_REP) {
if (simple < start) {
mod = (start - simple) / trig->rep;
@@ -385,7 +385,7 @@ static int GetNextTriggerDate(Trigger *trig, int start, int *err, int *nextstart
}
}
/* If it's a "BEFORE"-type skip, back up */
/* If it's a "BEFORE"-type skip, back up */
if (trig->skip == BEFORE_SKIP) {
int iter = 0;
while(iter++ <= MaxSatIter) {
@@ -406,7 +406,7 @@ static int GetNextTriggerDate(Trigger *trig, int start, int *err, int *nextstart
}
}
/* If it's an "AFTER"-type skip, jump ahead */
/* If it's an "AFTER"-type skip, jump ahead */
if (trig->skip == AFTER_SKIP) {
int iter = 0;
while (iter++ <= MaxSatIter) {
@@ -423,7 +423,12 @@ static int GetNextTriggerDate(Trigger *trig, int start, int *err, int *nextstart
}
}
/* Return the date */
/* If we've passed the UNTIL, then it's expired */
if (trig->until != NO_UNTIL && simple > trig->until) {
return -1;
}
/* Return the date */
return simple;
}

View File

@@ -3,6 +3,9 @@
# If you're writing a back-end, test it by feeding it the output
# of: remind -pp test-for-backends.rem
# All back-ends should endeavour to support: WEEK, SHADE, MOON, and
# COLOR/COLOUR. They may support other back-end-specific SPECIALs.
# Color and shade
REM 1 SPECIAL COLOR 128 0 0 Red
REM 2 SPECIAL COLOUR 0 128 0 British Green
@@ -17,11 +20,18 @@ REM [moondate(3)] SPECIAL MOON 3 -1 -1 [moontime(3)]
# Week
REM Monday SPECIAL WEEK (W[weekno()])
# PostScript
REM Wed PS Border Border 2 div moveto /Helvetica-Oblique findfont 6 scalefont setfont (oof!) show
# A normal reminder
REM 16 MSG A normal reminder
# PostScript - currently only supported by rem2ps
REM Wed PS Border Border 2 div moveto /Helvetica-Oblique findfont 6 scalefont setfont (oof PostScript!) show
# A SPECIAL that should be ignored
REM 15 SPECIAL RANDOM-STUFF ignore me and be happy
# A normal reminder
REM 16 MSG A normal reminder
# HTML - currently only supported by rem2html
REM 17 SPECIAL HTML I am <b>bold</b> HTML
# Pango - currently only supported by rem2pdf
REM 18 SPECIAL PANGO I am <b>bold</b> PANGO

View File

@@ -1042,7 +1042,7 @@ set a057 value("a05"+"6")
"a05" + "6" => "a056"
value("a056") => "SDFJHSDF KSJDFH KJSDFH KSJDFH"
set a058 version()
version() => "05.04.00"
version() => "05.04.01"
set a059 wkday(today())
today() => 1991-02-16
wkday(1991-02-16) => "Saturday"
@@ -2605,7 +2605,7 @@ a056 "SDFJHSDF KSJDFH KJSDFH KSJDFH"
a007 "1991-02-16"
a057 "SDFJHSDF KSJDFH KJSDFH KSJDFH"
a008 "11:44"
a058 "05.04.00"
a058 "05.04.01"
a059 "Saturday"
a010 12
a060 6
@@ -3153,7 +3153,7 @@ REM Mon 1992 UNTIL 1991-01-01 MSG Not diagnosed - not fully-specified start
../tests/test.rem(561): Expired
REM 1992-01-01 *1 UNTIL 1991-12-31 MSG Diagnosed
../tests/test.rem(562): Warning: UNTIL/THROUGH date earlier than start date
../tests/test.rem(562): Trig = Wednesday, 1 January, 1992
../tests/test.rem(562): Expired
set x '1992-01-01'
MSG [isconst(x)]
../tests/test.rem(564): Trig = Saturday, 16 February, 1991
@@ -3164,7 +3164,7 @@ isconst(1992-01-01) => 1
REM [x] *1 UNTIL 1991-12-31 MSG Diagnosed
x => 1992-01-01
../tests/test.rem(565): Warning: UNTIL/THROUGH date earlier than start date
../tests/test.rem(565): Trig = Wednesday, 1 January, 1992
../tests/test.rem(565): Expired
set x nonconst('1992-01-01')
nonconst(1992-01-01) => 1992-01-01
@@ -3176,7 +3176,7 @@ isconst(1992-01-01) => 0
REM [x] *1 UNTIL 1991-12-31 MSG Not diagnosed - nonconst expression
x => 1992-01-01
../tests/test.rem(569): Trig = Wednesday, 1 January, 1992
../tests/test.rem(569): Expired
REM MON FROM 1992-01-01 UNTIL 1991-12-31 MSG Diagnosed
../tests/test.rem(571): Warning: UNTIL/THROUGH date earlier than FROM date
@@ -5639,8 +5639,8 @@ REM SATISFY ""
REM SATISFY [version() > "01.00.00"]
../tests/test.rem(1055): SATISFY: expression has no reference to trigdate() or $T...
../tests/test.rem(1055): Trig = Saturday, 16 February, 1991
version() => "05.04.00"
"05.04.00" > "01.00.00" => 1
version() => "05.04.01"
"05.04.01" > "01.00.00" => 1
../tests/test.rem(1055): Trig(satisfied) = Saturday, 16 February, 1991
REM SATISFY [max(x, max(x, 1, 2, 3), 4, 5, 6) * 5]
../tests/test.rem(1056): SATISFY: expression has no reference to trigdate() or $T...
@@ -16575,6 +16575,8 @@ DEBUG -e
../tests/test.rem(1603): eval(): Too many recursive function calls
Base: 1991-02-09
Base: 1991-02-09
../tests/test.rem(1611): Expired
../tests/test.rem(1612): Expired
Variable hash table statistics:
Entries: 100143; Buckets: 87719; Non-empty Buckets: 66301
Maxlen: 5; Minlen: 0; Avglen: 1.142; Stddev: 0.878; Avg nonempty len: 1.510
@@ -23637,7 +23639,7 @@ SECURITY: Won't read world-writable file or directory!
Error reading include_dir/ww: Can't open file
SECURITY: Won't read world-writable file or directory!
Error reading include_dir/ww: No files matching *.rem
05.04.00
05.04.01
Enabling test mode: This is meant for the acceptance test.
Do not use --test in production.
In test mode, the system time is fixed at 2025-01-06@19:00

View File

@@ -1606,6 +1606,12 @@ set a eval(a)
REM 9 Feb 1991 *7 MSG Base: [trigbase()]
REM 9 Feb 1991 *1 MSG Base: [$Tb]
# The UNTIL bug
DEBUG +t
REM SECOND SATURDAY +300 UNTIL 1991-02-02 MSG [$T]
REM SECOND SATURDAY +300 UNTIL 1991-02-16 MSG [$T]
DEBUG -t
# Output expression-node stats
DEBUG +h