Re: 'org-structure-template-alist' is only partially working...
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" " lang=\"latex-mode\">\n?\n") > ;("t" "#+latex: " "?") > ;("x" "#+BEGIN_SRC latex\n?\n#+END_SRC" " lang=\"latex\">\n?\n") > ;("h" "#+begin_html\n?\n#+end_html" " style=\"html\">\n?\n") > ;("a" "#+begin_ascii\n?\n#+end_ascii") > ;("s" "#+BEGIN_SRC sh\n?+\n#+END_SRC" " lang=\"shell\">\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
'org-structure-template-alist' is only partially working...
I'm having great difficulty in getting 'org-structure-template-alist' to work properly. This is what I'm using - --8<---cut here---start->8--- #+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 --8<---cut here---end--->8--- http://www.sharons.org.uk TGmeds = http://www.tgmeds.org.uk DrugFacts = https://www.drugfacts.org.uk Debian 10.2, fluxbox 1.3.7, emacs 27.0.90, org 9.3.6