Get rid of #+setupfile: <FILE> to leave only #+include: <FILE>

This commit is contained in:
Gerard Vermeulen 2022-03-02 06:36:12 +01:00
parent 7f7f37e257
commit 7b40172d9c
2 changed files with 24 additions and 30 deletions

2
.gitignore vendored
View File

@ -18,11 +18,11 @@
dir-locals.el
example.py
include.org
latexmkrc
pyproject.toml
org-store-link
setup.cfg
setup-include.org
tree.svg
worg-backend-dependent-execution-update.org

View File

@ -2,8 +2,11 @@
#+author: Gerard Vermeulen
#+latex_class: article-local
#+latex_class_options: [11pt,a4paper,english,svgnames,tables]
#+setupfile: "setup-include.org"
#+include: "setup-include.org"
#+macro: kbd (eval (by-backend-kbd-org-macro $1))
#+property: header-args:emacs-lisp :exports code :results silent :tangle init.el
#+property: header-args:org :tangle include.org
#+startup: content
#+include: "include.org"
* Quick start
:PROPERTIES:
@ -1829,16 +1832,16 @@ compatibility, because the new way feels less hackish than the old way. A
practical difference is that new way source blocks (contrary to old way export
blocks) do not work in [[info:org#Export Settings][#+SETUPFILE: <FILE>]], but only in [[info:org#Export Settings][#+INCLUDE: <FILE>]] files.
*** [[info:org#Export Settings][#+SETUPFILE: and #+INCLUDE: usage]]
*** [[info:org#Export Settings][#+INCLUDE: <FILE> (info)]]
:PROPERTIES:
:CUSTOM_ID: sec:setupfile+include-usage
:CUSTOM_ID: sec:include-file-usage
:END:
Evaluation of the source block in listing
[[lst:make-source-block-with-export-keyword-settings]] produces the source block
that exports to listing [[lst:source-file-export-keyword-settings]] which shows the
first six lines of this [[file:README.org]] file. The last two lines show that
[[file:setup-include.org][setup-include.org]] is the argument for [[info:org#Export Settings][#+SETUPFILE:]] *and* [[info:org#Export Settings][#+INCLUDE:]].
that exports to listing [[lst:source-file-export-keyword-settings]] in order to show
the first nine lines of this [[file:README.org]] file. The last line shows that
[[file:include.org][include.org]] is the argument for [[info:org#Export Settings][#+INCLUDE: <FILE>]].
#+caption[Make setup and include file export keyword settings source block]:
#+caption: The shell script to make the source block containing the export
@ -1846,45 +1849,36 @@ first six lines of this [[file:README.org]] file. The last two lines show that
#+name: lst:make-source-block-with-export-keyword-settings
#+begin_src shell :exports both :results drawer
echo "#+caption[Source file export keyword settings]:"
echo "#+caption: The first six lines of README.org containing the export"
echo "#+caption: The first nine lines of README.org containing the export"
echo "#+caption: keyword settings."
echo "#+name: lst:source-file-export-keyword-settings"
echo "#+begin_src org :tangle no"
head -n 6 README.org
head -n 9 README.org
echo -n "#+end_src"
#+end_src
#+RESULTS: lst:make-source-block-with-export-keyword-settings
:results:
#+caption[Source file export keyword settings]:
#+caption: The first six lines of README.org containing the export
#+caption: The first nine lines of README.org containing the export
#+caption: keyword settings.
#+name: lst:source-file-export-keyword-settings
#+begin_src org :tangle no
#+title: Emacs setup for use with LaTeX, Org, and Python
#+author: Gerard Vermeulen
#+latex_class: article
#+babel: :cache no
#+latex_class: article-local
#+latex_class_options: [11pt,a4paper,english,svgnames,tables]
#+setupfile: "setup-include.org"
#+include: "setup-include.org"
#+macro: kbd (eval (by-backend-kbd-org-macro $1))
#+property: header-args:emacs-lisp :exports code :results silent :tangle init.el
#+property: header-args:org :tangle include.org
#+startup: content
#+end_src
:end:
Listing [[lst:setup-include-export-keyword-settings]] tangles into the
[[file:setup-include.org][setup-include.org]] file and listing [[lst:by-backend-kbd-org-macro]] defines
the tools for the [[https://orgmode.org/][Org mode]] =kbd= macro in [[file:setup-include.org][setup-include.org]].
#+caption[Setup and include file export keyword settings]:
#+caption: Setup and include file export keyword settings.
#+name: lst:setup-include-export-keyword-settings
#+begin_src org
,#+babel: :cache no
,#+macro: kbd (eval (by-backend-kbd-org-macro $1))
,#+options: ^:{}
,#+property: header-args:emacs-lisp :exports code :results silent :tangle init.el
,#+property: header-args:org :tangle setup-include.org
,#+startup: content
#+end_src
Listing [[lst:by-backend-kbd-org-macro]] defines the tools for the definition of the
[[https://orgmode.org/][Org mode]] =kbd= macro on the fifth line of listing
[[lst:source-file-export-keyword-settings]].
#+caption[Define the tools of the =Org-mode= =kbd= macro]:
#+caption: Define the tools for the =Org-mode= =kbd= macro.
@ -1904,7 +1898,7 @@ the tools for the [[https://orgmode.org/][Org mode]] =kbd= macro in [[file:setup
Listing [[lst:use-latex-header-1]], [[lst:use-latex-header-2]], [[lst:use-latex-header-3]],
[[lst:use-latex-header-4]], and [[lst:use-latex-header-5]] tangle into the
[[file:setup-include.org][setup-include.org]] file in order to create the [[https://www.latex-project.org/][LaTeX]] preamble.
[[file:include.org][include.org]] file in order to create the [[https://www.latex-project.org/][LaTeX]] preamble.
#+caption[LaTeX preamble: replacing the =Org-mode= default packages]:
#+caption: LaTeX preamble: replacing the =Org-mode= default packages.