* insert a remember template at point
@ 2010-05-29 22:04 Eraldo Helal
2010-05-29 23:05 ` Shelagh Manton
` (2 more replies)
0 siblings, 3 replies; 6+ messages in thread
From: Eraldo Helal @ 2010-05-29 22:04 UTC (permalink / raw)
To: Org-Mode
How can I insert a remember template at point?
Until now I had identical remember templates and yasnippets.
This is only a workaround and I would prefer to be able to insert a remember template at point since I have found it to have features I could not reproduce.
Greetings from Austria,
Eraldo
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: insert a remember template at point
2010-05-29 22:04 insert a remember template at point Eraldo Helal
@ 2010-05-29 23:05 ` Shelagh Manton
2010-05-29 23:24 ` Shelagh Manton
2010-06-01 7:54 ` Carsten Dominik
2 siblings, 0 replies; 6+ messages in thread
From: Shelagh Manton @ 2010-05-29 23:05 UTC (permalink / raw)
To: emacs-orgmode
On Sun, 30 May 2010 00:04:08 +0200, Eraldo Helal wrote:
> How can I insert a remember template at point?
>
> Until now I had identical remember templates and yasnippets. This is
> only a workaround and I would prefer to be able to insert a remember
> template at point since I have found it to have features I could not
> reproduce.
I had this problem about a year ago. The trick is to insert a function
that returns the strings you need.
For example this is the function I used.
(defun org-csa () ;this strange function only *returns* the desired
;text, not inserts to the buffer.
" :PROPERTIES:
:ORDERED: t
:END:
*** TODO [[ooo:\"CSA Template.ott\" &][fill out template form]]
*** TODO [[shell:claws-mail pm@example.com.au &][submit for approval/
fixes]]
*** TODO save to text
*** TODO [[shell:claws-mail dr@example.com][send it to Darren]]")
Then you make your remember template call this function.
Like this:
("CSA" ?C "* TODO %^{topic} [/] %^g\n %t\n %(org-csa) \n %&" "~/.org/
CSA.org" bottom)
Cheers
Shelagh
> Greetings from Austria,
> Eraldo
>
> _______________________________________________ Emacs-orgmode mailing
> list
> Please use `Reply All' to send replies to the list.
> Emacs-orgmode@gnu.org
> http://lists.gnu.org/mailman/listinfo/emacs-orgmode
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: insert a remember template at point
2010-05-29 22:04 insert a remember template at point Eraldo Helal
2010-05-29 23:05 ` Shelagh Manton
@ 2010-05-29 23:24 ` Shelagh Manton
2010-06-01 7:54 ` Carsten Dominik
2 siblings, 0 replies; 6+ messages in thread
From: Shelagh Manton @ 2010-05-29 23:24 UTC (permalink / raw)
To: emacs-orgmode
On Sun, 30 May 2010 00:04:08 +0200, Eraldo Helal wrote:
> How can I insert a remember template at point?
>
> Until now I had identical remember templates and yasnippets. This is
> only a workaround and I would prefer to be able to insert a remember
> template at point since I have found it to have features I could not
> reproduce.
>
> Greetings from Austria,
> Eraldo
>
Actually now ai read your post again more carefully, I think my last post
is not really what you are after.
Shelagh
> _______________________________________________ Emacs-orgmode mailing
> list
> Please use `Reply All' to send replies to the list.
> Emacs-orgmode@gnu.org
> http://lists.gnu.org/mailman/listinfo/emacs-orgmode
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: insert a remember template at point
2010-05-29 22:04 insert a remember template at point Eraldo Helal
2010-05-29 23:05 ` Shelagh Manton
2010-05-29 23:24 ` Shelagh Manton
@ 2010-06-01 7:54 ` Carsten Dominik
2010-06-01 23:47 ` Eraldo Helal
2 siblings, 1 reply; 6+ messages in thread
From: Carsten Dominik @ 2010-06-01 7:54 UTC (permalink / raw)
To: Eraldo Helal; +Cc: Org-Mode
On May 30, 2010, at 12:04 AM, Eraldo Helal wrote:
> How can I insert a remember template at point?
>
> Until now I had identical remember templates and yasnippets.
> This is only a workaround and I would prefer to be able to insert a
> remember template at point since I have found it to have features I
> could not reproduce.
Hi Eraldo,
currently there is no easy way to do this.
One way to hack it would be to write a function that temporarily
modifies to make
all remember templates point to the current location.
So something like (untested)
(defun my-remember-here ()
(interactive)
(let ((file buffer-file-name)
(heading (org-get-heading 'no-tags))
(org-remember-templates
(mapcar (lambda (x) (list (nth 0 x) (nth 1 x) (nth 2 x) file heading))
org-remember-templates)))
(call-interatively 'org-remember)))
- Carsten
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: insert a remember template at point
2010-06-01 7:54 ` Carsten Dominik
@ 2010-06-01 23:47 ` Eraldo Helal
2010-06-02 6:49 ` Carsten Dominik
0 siblings, 1 reply; 6+ messages in thread
From: Eraldo Helal @ 2010-06-01 23:47 UTC (permalink / raw)
To: Carsten Dominik; +Cc: Org-Mode
Carsten Dominik <carsten.dominik@gmail.com> writes:
> currently there is no easy way to do this.
While I have hoped to hear the opposite, it's good to know the truth. :)
> One way to hack it would be to write a function that temporarily
> modifies to make
> all remember templates point to the current location.
I am again baffled how fast you get from request to code. ^^
I will definitely try out the function you posted.
Thanks a lot for that.
I will give feedback on it soon.
Is there anything else I can do (besides speeding up projects like
learning lisp) to make that feature part of remember?
That would go in org-remember if I understand that correctly.
Greetings from Austria,
Eraldo
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: insert a remember template at point
2010-06-01 23:47 ` Eraldo Helal
@ 2010-06-02 6:49 ` Carsten Dominik
0 siblings, 0 replies; 6+ messages in thread
From: Carsten Dominik @ 2010-06-02 6:49 UTC (permalink / raw)
To: Eraldo Helal; +Cc: Org-Mode
On Jun 2, 2010, at 1:47 AM, Eraldo Helal wrote:
> Carsten Dominik <carsten.dominik@gmail.com> writes:
>
>> currently there is no easy way to do this.
> While I have hoped to hear the opposite, it's good to know the
> truth. :)
>
>> One way to hack it would be to write a function that temporarily
>> modifies to make
>> all remember templates point to the current location.
> I am again baffled how fast you get from request to code. ^^
> I will definitely try out the function you posted.
> Thanks a lot for that.
> I will give feedback on it soon.
>
> Is there anything else I can do (besides speeding up projects like
> learning lisp) to make that feature part of remember?
> That would go in org-remember if I understand that correctly.
I still have plans for rewriting the entire remember stuff.
This will be one of the features - if that ever happens... :)
- Carsten
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2010-06-02 6:49 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-05-29 22:04 insert a remember template at point Eraldo Helal
2010-05-29 23:05 ` Shelagh Manton
2010-05-29 23:24 ` Shelagh Manton
2010-06-01 7:54 ` Carsten Dominik
2010-06-01 23:47 ` Eraldo Helal
2010-06-02 6:49 ` Carsten Dominik
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.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).