emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Marco Wahl <marcowahlsoft@gmail.com>
To: Sharon Kimble <boudiccas@skimble.plus.com>
Cc: emacs-orgmode@gnu.org
Subject: Re: 'org-structure-template-alist' is only partially working...
Date: Wed, 01 Apr 2020 13:06:26 +0200	[thread overview]
Message-ID: <848sjffost.fsf@gmail.com> (raw)
In-Reply-To: <875zeja4kw.fsf@skimble.plus.com> (Sharon Kimble's message of "Wed, 01 Apr 2020 11:22:07 +0100")

Sharon Kimble <boudiccas@skimble.plus.com> writes:

> I'm having great difficulty in getting 'org-structure-template-alist' to work properly.
>
> This is what I'm using -  
>
> #+BEGIN_SRC emacs-lisp
> ;(require 'org-tempo)
> (setq org-structure-template-alist
>        '('("s" . "src emacs-lisp")
>         ;("e" . "example")
>         '("q" . "quote")
>         '("v" . "verse")
>         '("C" . "comment")
>         '("b" . "src latex")
>         ;("m" "#+begin_src latex-mode\n?\n#+end_src" "<src lang=\"latex-mode\">\n?\n</src>")
>         ;("t" "#+latex: " "<literal style=\"latex\">?</literal>")
>         ;("x" "#+BEGIN_SRC latex\n?\n#+END_SRC" "<src lang=\"latex\">\n?\n</src>")
>         ;("h" "#+begin_html\n?\n#+end_html" "<literal style=\"html\">\n?\n</literal>")
>         ;("a" "#+begin_ascii\n?\n#+end_ascii")
>         ;("s" "#+BEGIN_SRC sh\n?+\n#+END_SRC" "<src lang=\"shell\">\n?\n</src>")
>         '("l" . "emacs-lisp")
>         ;("u" "#+begin_src emacs-lisp\n\(use-package %0\n\:ensure t)\n\#+end_src")
>         '("i" . "index")
>         ;("p" "#+BEGIN_COMMENT\n?\n#+END_COMMENT" "<comment>\n?\n</comment>")
>         '("f" . "src file")))
> #+END_SRC
>
> <s works
>
> but <q, <v, <C, <b, <l, <i, and <f do *not* work!
>
> So how can I get it to actually work please?

AFAICS the evaluation of (require 'org-tempo) makes the structure
templates working in the sense you expect.

If you want this permanently you could add the line (require 'org-tempo)
to your Emacs init file.

Alternatively you could customize variable org-modules { M-x
customize-variable RET org-modules RET } and choose org-modules, I
think.


HTH,
-- Marco

      reply	other threads:[~2020-04-01 11:06 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-01 10:22 'org-structure-template-alist' is only partially working Sharon Kimble
2020-04-01 11:06 ` Marco Wahl [this message]

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.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=848sjffost.fsf@gmail.com \
    --to=marcowahlsoft@gmail.com \
    --cc=boudiccas@skimble.plus.com \
    --cc=emacs-orgmode@gnu.org \
    /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.
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).