emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: 'No applicable method' error when calling 'gnus-icalendar-save-part'


From: James Thomas
Subject: Re: 'No applicable method' error when calling 'gnus-icalendar-save-part'
Date: Sun, 13 Oct 2024 05:41:01 +0530
User-agent: Gnus/5.13 (Gnus v5.13)

Fabio Natali wrote:

> Hi All,
>
> This is to bring up an issue I found while using gnus-icalendar. It's
> the first time I use this library, not sure whether this is a bug or
> simply incorrect usage on my part.
>
> My setup is Emacs 29.4 + Notmuch 0.38.2.
>
> My Emacs configuration includes:
>
> (require 'org-agenda)
> (require 'gnus-icalendar)
> (setq gnus-icalendar-org-capture-file "~/calendar.org")
> (setq gnus-icalendar-org-capture-headline '("Calendar"))
> (gnus-icalendar-org-setup)
>
> (defun notmuch-show-import-icalendar-part ()
>   "Import the iCalendar part at point to Org Agenda."
>   (interactive)
>   (notmuch-show-apply-to-current-part-handle #'gnus-icalendar-save-part))
>
>
> Calling 'notmuch-show-import-icalendar-part' when on top of an iCalendar
> attachment results in this error:

(I don't use this, yet, so this is all speculative)

Have you tried using gnus-icalendar-sync-event-to-org? Something like:

(defun notmuch-show-import-icalendar-part ()
  "Import the iCalendar part at point to Org Agenda."
  (interactive)
  (let (gnus-icalendar-reply-status)
    (notmuch-show-apply-to-current-part-handle
    #'gnus-icalendar-sync-event-to-org)))

Because gnus-icalendar-save-part is not interactive. That honor falls to
gnus-icalendar-save-event and seems to be integrated with Gnus.

Regards,
James




reply via email to

[Prev in Thread] Current Thread [Next in Thread]