From: Yuchen Pei <hi@ypei.me>
To: Michael Heerdegen <michael_heerdegen@web.de>
Cc: 50195@debbugs.gnu.org
Subject: bug#50195: [PATCH] Adding diary-offset, a diary-sexp offsetting another diary-sexp.
Date: Fri, 27 Aug 2021 23:11:34 +1000 [thread overview]
Message-ID: <87ilzr9gmx.fsf@ypei.me> (raw)
In-Reply-To: <874kbcijrt.fsf@web.de>
[-- Attachment #1: Type: text/plain, Size: 1410 bytes --]
Michael Heerdegen <michael_heerdegen@web.de> writes:
> Yuchen Pei <hi@ypei.me> writes:
>
>> A bit like diary-remind, as a diary-sexp rather than reminder,
>> and
>> also support both positive and negative offsets.
>
> Because we are just talking about it: my personal solution for
> this kind
> of problem: I extended the diary language with some date
> arithmetic
> functions and a `date-let' macro, that allows you to solve the
> same task
> like
>
> (date-let ((date+ date 2))
> SEXP)
>
> An advantage is that this saves one layer of `eval', and it
> allows the
> delta of days to be an expression (that might depend on the
> DATE).
Interesting - I never thought of defining my own let macro.
>
> I also worked on finer grained solutions for the problems of the
> kind
> "every Nth Xday of the month unless it's a day that fulfills
> some TEST
> (e.g., it's a holiday), then use an alternative date. Useful
> for
> specifying rules for garbage collection (real-life garbage, not
> Emacs
> gc).
>
> I planned to provide these things as a separate library, and I'm
> not
> against what has been supposed here, just wanted to mention an
> alternative view on the problem.
Thanks, I'll be curious to see your library when it gets
published.
>
> Michael.
--
Best,
Yuchen
PGP Key: 47F9 D050 1E11 8879 9040 4941 2126 7E93 EF86 DFD0
<https://ypei.me/assets/ypei-pubkey.txt>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 243 bytes --]
prev parent reply other threads:[~2021-08-27 13:11 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-08-25 3:46 bug#50195: [PATCH] Adding diary-offset, a diary-sexp offsetting another diary-sexp Yuchen Pei
2021-08-25 11:31 ` Lars Ingebrigtsen
2021-08-25 11:52 ` Eli Zaretskii
2021-08-25 12:06 ` Lars Ingebrigtsen
2021-08-25 12:24 ` Eli Zaretskii
2021-08-25 12:38 ` Lars Ingebrigtsen
2021-08-25 15:22 ` Michael Heerdegen
2021-08-25 15:32 ` Michael Heerdegen
2021-08-25 16:07 ` Eli Zaretskii
2021-08-25 16:22 ` Michael Heerdegen
2021-08-26 6:52 ` Yuchen Pei
2021-08-26 9:26 ` Michael Heerdegen
2021-08-26 6:49 ` bug#50195: [PATCH] Adding diary-offset to diary-lib.el Yuchen Pei
2021-08-26 6:54 ` Yuchen Pei
2021-08-27 13:16 ` Yuchen Pei
2021-09-03 22:40 ` Yuchen Pei
2021-09-04 6:15 ` Eli Zaretskii
2021-09-04 6:29 ` Lars Ingebrigtsen
2021-09-04 7:21 ` Yuchen Pei
2021-08-26 10:26 ` bug#50195: [PATCH] Adding diary-offset, a diary-sexp offsetting another diary-sexp Michael Heerdegen
2021-08-27 13:11 ` Yuchen Pei [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87ilzr9gmx.fsf@ypei.me \
--to=hi@ypei.me \
--cc=50195@debbugs.gnu.org \
--cc=michael_heerdegen@web.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).