* gnus-icalendar export to org does not include time stamp if no description
@ 2019-04-14 11:00 Eric S Fraga
2019-04-14 11:21 ` Robert Pluim
0 siblings, 1 reply; 7+ messages in thread
From: Eric S Fraga @ 2019-04-14 11:00 UTC (permalink / raw)
To: ding
Hello,
I don't know whether to post this here, in the org mailing list, or an
emacs group...
I use gnus-icalendar-event-export to create org entries from calendar
invites. For some reason, the time stamp associated with the entry is
only exported if the invite has a description field (line 483 of
gnus-icalendar.el in git version of Emacs). As the description field is
optional, some invites do not get exported properly. This seems wrong
to me.
I could try fixing this myself but I'm not proficient with elisp...
Please advise.
Thanks,
eric
--
Eric S Fraga via Emacs 27.0.50 & org 9.2.3 on Debian buster/sid
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: gnus-icalendar export to org does not include time stamp if no description
2019-04-14 11:00 gnus-icalendar export to org does not include time stamp if no description Eric S Fraga
@ 2019-04-14 11:21 ` Robert Pluim
2019-04-14 11:41 ` Eric S Fraga
2019-04-14 11:58 ` Eric S Fraga
0 siblings, 2 replies; 7+ messages in thread
From: Robert Pluim @ 2019-04-14 11:21 UTC (permalink / raw)
To: Eric S Fraga; +Cc: ding
>>>>> On Sun, 14 Apr 2019 12:00:24 +0100, Eric S Fraga <e.fraga@ucl.ac.uk> said:
Eric> Hello, I don't know whether to post this here, in the org
Eric> mailing list, or an emacs group...
Eric> I use gnus-icalendar-event-export to create org entries from
Eric> calendar invites. For some reason, the time stamp
Eric> associated with the entry is only exported if the invite has
Eric> a description field (line 483 of gnus-icalendar.el in git
Eric> version of Emacs). As the description field is optional,
Eric> some invites do not get exported properly. This seems wrong
Eric> to me.
Eric> I could try fixing this myself but I'm not proficient with
Eric> elisp...
Totally untested, as I donʼt use gnus-icalendar at all.
diff --git a/lisp/gnus/gnus-icalendar.el b/lisp/gnus/gnus-icalendar.el
index 28020a1fd0..64cc3f92a9 100644
--- a/lisp/gnus/gnus-icalendar.el
+++ b/lisp/gnus/gnus-icalendar.el
@@ -480,14 +480,14 @@ gnus-icalendar--format-participant-list
(org-entry-put (point) (car prop) (cdr prop)))
props))
- (when description
- (save-restriction
- (narrow-to-region (point) (point))
- (insert (gnus-icalendar-event:org-timestamp event)
- "\n\n"
- description)
- (indent-region (point-min) (point-max) 2)
- (fill-region (point-min) (point-max))))
+ (save-restriction
+ (narrow-to-region (point) (point))
+ (insert (gnus-icalendar-event:org-timestamp event)
+ "\n\n")
+ (when description
+ (insert description))
+ (indent-region (point-min) (point-max) 2)
+ (fill-region (point-min) (point-max)))
(buffer-string))))
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: gnus-icalendar export to org does not include time stamp if no description
2019-04-14 11:21 ` Robert Pluim
@ 2019-04-14 11:41 ` Eric S Fraga
2019-04-14 12:03 ` Robert Pluim
2019-04-14 11:58 ` Eric S Fraga
1 sibling, 1 reply; 7+ messages in thread
From: Eric S Fraga @ 2019-04-14 11:41 UTC (permalink / raw)
To: ding
On Sunday, 14 Apr 2019 at 13:21, Robert Pluim wrote:
> Totally untested, as I donʼt use gnus-icalendar at all.
Looks reasonable (i.e. makes sense to me!). I'll try this out. Should
this patch be suggested on the emacs-devel list or will somebody in this
group pick it up?
Thanks,
eric
--
Eric S Fraga via Emacs 27.0.50 & org 9.2.3 on Debian buster/sid
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: gnus-icalendar export to org does not include time stamp if no description
2019-04-14 11:41 ` Eric S Fraga
@ 2019-04-14 12:03 ` Robert Pluim
2019-04-14 12:11 ` Eric S Fraga
0 siblings, 1 reply; 7+ messages in thread
From: Robert Pluim @ 2019-04-14 12:03 UTC (permalink / raw)
To: Eric S Fraga; +Cc: ding
>>>>> On Sun, 14 Apr 2019 12:41:02 +0100, Eric S Fraga <e.fraga@ucl.ac.uk> said:
Eric> On Sunday, 14 Apr 2019 at 13:21, Robert Pluim wrote:
>> Totally untested, as I donʼt use gnus-icalendar at all.
Eric> Looks reasonable (i.e. makes sense to me!). I'll try this
Eric> out. Should this patch be suggested on the emacs-devel list
Eric> or will somebody in this group pick it up?
You or someone else who actually uses that function should suggest it
there (assuming the patch works, of course).
Robert
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: gnus-icalendar export to org does not include time stamp if no description
2019-04-14 11:21 ` Robert Pluim
2019-04-14 11:41 ` Eric S Fraga
@ 2019-04-14 11:58 ` Eric S Fraga
2019-06-22 11:16 ` Lars Ingebrigtsen
1 sibling, 1 reply; 7+ messages in thread
From: Eric S Fraga @ 2019-04-14 11:58 UTC (permalink / raw)
To: ding
On Sunday, 14 Apr 2019 at 13:21, Robert Pluim wrote:
> Totally untested, as I donʼt use gnus-icalendar at all.
I've tested it a little. Seems to work just fine. Many thanks!
--
Eric S Fraga via Emacs 27.0.50 & org 9.2.3 on Debian buster/sid
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2019-06-22 11:16 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-04-14 11:00 gnus-icalendar export to org does not include time stamp if no description Eric S Fraga
2019-04-14 11:21 ` Robert Pluim
2019-04-14 11:41 ` Eric S Fraga
2019-04-14 12:03 ` Robert Pluim
2019-04-14 12:11 ` Eric S Fraga
2019-04-14 11:58 ` Eric S Fraga
2019-06-22 11:16 ` Lars Ingebrigtsen
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 NNTP newsgroup(s).