From mboxrd@z Thu Jan 1 00:00:00 1970 From: Marco Wahl Subject: Re: 'org-structure-template-alist' is only partially working... Date: Wed, 01 Apr 2020 13:06:26 +0200 Message-ID: <848sjffost.fsf@gmail.com> References: <875zeja4kw.fsf@skimble.plus.com> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:470:142:3::10]:59268) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jJbCY-0002d3-K6 for emacs-orgmode@gnu.org; Wed, 01 Apr 2020 07:06:31 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1jJbCX-0006hb-KJ for emacs-orgmode@gnu.org; Wed, 01 Apr 2020 07:06:30 -0400 Received: from mail-wr1-x433.google.com ([2a00:1450:4864:20::433]:35815) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1jJbCX-0006h1-EV for emacs-orgmode@gnu.org; Wed, 01 Apr 2020 07:06:29 -0400 Received: by mail-wr1-x433.google.com with SMTP id d5so30103078wrn.2 for ; Wed, 01 Apr 2020 04:06:29 -0700 (PDT) In-Reply-To: <875zeja4kw.fsf@skimble.plus.com> (Sharon Kimble's message of "Wed, 01 Apr 2020 11:22:07 +0100") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane-mx.org@gnu.org Sender: "Emacs-orgmode" To: Sharon Kimble Cc: emacs-orgmode@gnu.org Sharon Kimble 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" "\n?\n") > ;("t" "#+latex: " "?") > ;("x" "#+BEGIN_SRC latex\n?\n#+END_SRC" "\n?\n") > ;("h" "#+begin_html\n?\n#+end_html" "\n?\n") > ;("a" "#+begin_ascii\n?\n#+end_ascii") > ;("s" "#+BEGIN_SRC sh\n?+\n#+END_SRC" "\n?\n") > '("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" "\n?\n") > '("f" . "src file"))) > #+END_SRC > > > but > 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