Commit Graph

165 Commits

Author SHA1 Message Date
Dianne Skoll 3b43222585 Add the triginfo("header") function and corresponding %<...> substitution sequence. 2025-02-01 14:39:06 -05:00
Dianne Skoll 0ebaaa4097 Add optional add_quote argument to escape() 2025-02-01 10:58:55 -05:00
Dianne Skoll 694c4099d1 Add \xAA sequence for parsing quoted strings; add the escape() built-in function; update docs. 2025-02-01 10:36:38 -05:00
Dianne Skoll 8d09abc363 Use snprintf in favor of sprintf almost everywhere.
Remind unit tests / tests (push) Successful in 35s
2025-01-22 11:11:08 -05:00
Dianne Skoll 4f351c089e Add the "-dq" debugging flag, for outputing TRANSLATE commands needed by a reminder script.
Remind unit tests / tests (push) Successful in 44s
2025-01-17 08:46:29 -05:00
Dianne Skoll 17ccf5d2b4 Make more messages translatable. 2025-01-14 11:27:47 -05:00
Dianne Skoll 562cec3dc8 Mass-update copyright date to 2025. 2024-12-29 13:47:07 -05:00
Dianne Skoll 5a2914f6c7 Start hash tables with 7 buckets instead of 17; print more detailed hash stats with -ds; consistently use ErrFp instead of stderr
Remind unit tests / tests (push) Successful in 32s
2024-12-14 11:52:16 -05:00
Dianne Skoll c7ca1b4baa Get rid of the DyamicFoo hacks and make most translatable variables live in the translation table. 2024-12-12 11:43:03 -05:00
Dianne Skoll d3e6c81a3a Synthesize mixed-case translations. 2024-12-10 17:02:41 -05:00
Dianne Skoll 585d45e4a1 Completely remove support for compile-time localization.
All localization is now done at run-time.
2024-12-10 10:58:09 -05:00
Dianne Skoll d9796e72e5 Allow error messages to be localized. 2024-12-09 19:55:23 -05:00
Dianne Skoll 973019c4c7 Implement TRANSLATE keyword. 2024-12-09 12:56:40 -05:00
Dianne Skoll 54e788b765 Make the sun functions return E_SWERR if BASE != 1990.
Remind unit tests / tests (push) Successful in 44s
2024-12-04 13:12:40 -05:00
Dianne Skoll 4283feff31 Change #error to #warning so cppcheck can analyze funcs.c 2024-12-04 13:10:03 -05:00
Dianne Skoll 062a84b758 Simplify HAS_DATE and HAS_TIME macros by making type values into bitmasks.
Remind unit tests / tests (push) Successful in 34s
2024-12-02 09:50:33 -05:00
Dianne Skoll 533718b0a0 Massive whitespace cleanups: Untabify everything. 2024-11-08 20:30:13 -05:00
Dianne Skoll 8a5b88338b Add --print-tokens long option to dump Remind tokens to stdout. 2024-09-08 10:29:49 -04:00
Dianne Skoll ed021d3f46 Let IIF's boolean arg be any type... we use truthy(). 2024-08-28 20:41:21 -04:00
Dianne Skoll 27d0fda280 Factor out truthy code from Fiif 2024-08-28 20:38:04 -04:00
Dianne Skoll 7b098e95ad Make error messages more consistent. 2024-08-28 18:21:35 -04:00
Dianne Skoll 0b28dde9c7 Add optional argument to ampm() to specify that hour should be zero-padded to two digits.
Remind unit tests / tests (push) Successful in 46s
2024-08-22 17:38:54 -04:00
Dianne Skoll ce8803dde9 The zero-argument form of weekno() is not constant. 2024-06-07 21:22:32 -04:00
Dianne Skoll 60ca5d45e3 Convert "isany" to short-circuit evaluation. 2024-06-07 15:55:12 -04:00
Dianne Skoll d77d9854d2 Remove src/expr.h - everything in it is now in types.h or protos.h 2024-06-02 10:26:41 -04:00
Dianne Skoll 8dbae776c9 Fix SEGV. 2024-06-01 09:27:27 -04:00
Dianne Skoll b78702cc53 Assume all function names are lower-case. 2024-06-01 08:46:27 -04:00
Dianne Skoll d2b43605ad Completely revamp expression engine. 2024-06-01 08:19:12 -04:00
Dianne Skoll 1be84525b1 Don't rely on behavior of "%" with negative args. 2024-04-22 09:57:32 -04:00
Dianne Skoll c03a95ad94 Use built-in versions of strdup, strcasecmp and strncasecmp instead of writing our own. 2024-04-21 14:44:24 -04:00
Dianne Skoll 27c8737f3a Only save trigger date when computing it, not while parsing. 2024-04-18 23:41:47 -04:00
Dianne Skoll 77373eed2d Fix tests on FreeBSD. We need to copy the results of getenv or when we change it, it will be overwritten. 2024-04-02 08:54:40 -04:00
Dianne Skoll 5fbf1d82e4 Remove duplicated line. 2024-03-22 11:23:04 -04:00
Dianne Skoll 55eb3ebe95 Add multitrig built-in function which is how trig() should originally have been done. 2024-03-22 11:21:26 -04:00
Dianne Skoll 95523c8f10 Convert cosd() function into a macro. 2024-03-19 16:26:07 -04:00
Dianne Skoll 61fcc1b275 Add "s" debugging flag to see expression-parsing stack high-water marks.
Reduce default value stack size from 1000 to 100.
2024-03-13 12:06:55 -04:00
Dianne Skoll 6b798d5f7c Allow arg to easterdate() and orthodoxeaster() to be omitted, defaulting it to today(). 2024-02-26 17:19:22 -05:00
Dianne Skoll 72d10178bf Mass-update copyright year to 2024. 2023-12-31 12:05:03 -05:00
Dianne Skoll 6e53fd6924 Refactor code: Replace SystemTime(x)/60 with MinutesPastMidnight(x) 2023-12-09 10:41:03 -05:00
Dianne Skoll f7bb91320c Return an error rather than (DATETIME) -1 if soleq fails 2023-10-08 11:58:28 -04:00
Dianne Skoll c11071a859 Undo fixes - the problem is with mktime on 32-bit systems.
Remove tests that break on 32-bit systems.
2023-10-08 11:49:44 -04:00
Dianne Skoll 53cbcc22db Fix typo 2023-10-08 11:35:06 -04:00
Dianne Skoll af9dcec3e9 Use "long long" for 32-bit systems. 2023-10-08 11:34:10 -04:00
Dianne Skoll 734cc61489 Better logic for checking if we should close TTY fd. 2023-10-02 23:07:34 -04:00
Dianne Skoll cf0d958da5 Add optional "step" parameter to slide() to match nonomitted(). 2023-07-23 14:43:13 -04:00
Dianne Skoll 1baa6dab0c Updates to nomomitted:
o Add optional "step" argument
  o If start > end, swap the first two arguments
  o Update man page and tests
2023-07-15 13:04:47 -04:00
Dianne Skoll 11375729db Remove unnecessary #include. 2023-03-19 09:43:57 -04:00
Dianne Skoll d4a183f3bf Add htmlstriptags function. 2023-03-02 11:40:03 -05:00
Dianne Skoll 87e392de6c Check for E_NOMEM conditions. 2023-03-02 09:43:56 -05:00
Dianne Skoll afc1667e64 Implement htmlescape() built-in function. 2023-03-02 09:39:14 -05:00