unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Michael Heerdegen <michael_heerdegen@web.de>
To: Marc Coquand <marc@mccd.space>
Cc: help-gnu-emacs@gnu.org
Subject: Re: Adding timestamp entry to diary with insert-day command?
Date: Wed, 09 Oct 2024 00:37:32 +0200	[thread overview]
Message-ID: <875xq2jk5v.fsf@web.de> (raw)
In-Reply-To: <87msjg9ioy.fsf@bogo.lt> (Marc Coquand's message of "Mon, 07 Oct 2024 15:48:31 +0300")

Marc Coquand <marc@mccd.space> writes:

> I have began using diary, and quite like the simple format.
>
> I'd like to change the default insert-day entry format, and add a
> timestamp as well since all my entries are time-stamped.

How would that look like in your diary file in the end?

> Is there a way to do so?

I think you would define your own function, a variant of
`diary-insert-entry', and use that instead of `diary-insert-entry'.  I
guess you would make the first argument of `diary-make-entry' to include
your time stamp.

> Bonus question: Is it also possible to use org-capture to insert diary
> entries with a timestamp included?

Into the _diary_?  org-capture relies on org-mode (it uses a narrowed
version of the org buffer of the target org file for input).  Getting
that work would be that kind of hack where it is very likely that you'll
regret it later.  Unless I misunderstood what you have in mind,
honestly, I would not try to marry those concepts.


Michael.



  reply	other threads:[~2024-10-08 22:37 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-07 12:48 Adding timestamp entry to diary with insert-day command? Marc Coquand
2024-10-08 22:37 ` Michael Heerdegen [this message]
2024-10-09 18:20   ` Marc Coquand

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=875xq2jk5v.fsf@web.de \
    --to=michael_heerdegen@web.de \
    --cc=help-gnu-emacs@gnu.org \
    --cc=marc@mccd.space \
    /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.
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).