help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: Appending to a list


From: steve-humphreys
Subject: Re: Appending to a list
Date: Mon, 14 Dec 2020 03:54:37 +0100

Consider I have the following two templates, and want a make a list
named "tmplt-animal", which I can then pass to org-capture-templates.

(setq org-capture-templates tmplt-animal)

How can I use "push" to do that?

-------- template code --------

(setq tmplt-bird `(

("1" "Toucan" entry
(file "~/animal.org")
,(concat
"* Toucan\n"
" Species:\n"
" Region: %?\n"
" Brief:\n"
" Entered: %T\n"))

("2" "King Fisher" entry
(file "~/animal.org")
,(concat
"* King Fisher"
" Species:\n"
" Region: %?\n"
" Brief:\n"
" Entered: %T\n")) ))

(setq tmplt-Amphibian `(

("3" "Frog or Toad" entry
(file "~/animal.org")
,(concat
"* Frog or Toad\n"
" Species:\n"
" Region: %?\n"
" Brief:\n"
" Entered: %T\n"))

("4" "Salamander" entry
(file "~/animal.org")
,(concat
"* King Fisher"
" Species:\n"
" Region: %?\n"
" Brief:\n"
" Entered: %T\n")) ))

> Sent: Monday, December 14, 2020 at 1:37 AM
> From: "Emanuel Berg via Users list for the GNU Emacs text editor" 
> <help-gnu-emacs@gnu.org>
> To: help-gnu-emacs@gnu.org
> Subject: Re: Appending to a list
>
> steve-humphreys wrote:
>
> > I don't mind inserting at the beginning if that makes things
> > more efficient. :)
>
> In your particular use case it will probably never be an issue
> of efficiency but as a programmer I guess the more details you
> know and understand and can put to good use the better...
>
> --
> underground experts united
> http://user.it.uu.se/~embe8573
> https://dataswamp.org/~incal
>
>
>



reply via email to

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