Commit graph

3186 commits

Author SHA1 Message Date
Jonas Bernoulli 3d0f592de7 ox-texinfo: Add function for use by kbd macro
* doc/doc-setup.org: Use org-texinfo-kbd-macro for kbd macro.
* doc/org-manual.org: Add new node "Key bindings in Texinfo export".
* lisp/ox-texinfo.el (org-texinfo--quoted-keys-regexp): New variable.
* lisp/ox-texinfo.el (org-texinfo-kbd-macro): New function.
2022-02-08 22:45:27 +01:00
Samim Pezeshki 22e6ed6b89 agenda: Add header to agenda clock report table
* lisp/org-agenda.el (org-agenda-list): Add header to agenda clock
report table.

TINYCHANGE
2022-01-26 21:07:49 +01:00
Kyle Meyer aae2ac3a68 Merge branch 'bugfix' 2022-01-01 15:21:37 -05:00
Kyle Meyer 5a229cbc44 Update copyright year to 2022 2022-01-01 15:17:08 -05:00
Marco Wahl be03334a7e Merge branch 'bugfix' into main 2021-12-21 12:13:46 +01:00
Marco Wahl b6c5f028a0 Fix parallel make of docs
* doc/Makefile: Split multiple target "org.texi orgguide.texi".
* mk/org-fixup.el (org-make-manual, org-make-guide):  New functions.
  (org-make-manuals): Make obsolete.

Reported by Ulrich Müller.  https://list.orgmode.org/uee67gr96@gentoo.org/
2021-12-21 12:12:21 +01:00
Kyle Meyer 8ca254696b Merge branch 'bugfix' 2021-12-02 20:43:14 -05:00
Kyle Meyer 0acd2fed20 manual: Rename nodes to silence Emacs name check
* doc/org-manual.org (Advanced Export Configuration):
(Extracting Source Code): Rename "Hooks" subheading so that ox-texinfo
does not make it unique by appending " (N)".

The Emacs repo has a check for problematic characters in info nodes
that flagged "Hooks (2)" (bug#52126).  As mentioned in that thread,
this case is actually probably not problematic because the name
doesn't _start_ with "(".  However, it's easy enough to sidestep the
warning, and adding the extra context doesn't hurt.
2021-12-02 20:40:58 -05:00
Ihor Radchenko d8293676c3
Merge branch 'bugfix' 2021-11-23 21:51:46 +08:00
Ihor Radchenko ce0f5c3beb
org-manual.org: Clarify how to handle markup ambiguity
* doc/org-manual.org (Emphasis and Monospace): Advice users to insert
zero width space to force Org ignore emphasis markers.
2021-11-23 21:41:11 +08:00
TEC b21d11c614
Document new :tangle-mode forms
* etc/ORG-NEWS: Mention new forms that :tangle-mode accepts.

* doc/org-manual.org (Header arguments): Mention new forms that
:tangle-mode accepts.
2021-11-21 03:06:20 +08:00
Kyle Meyer af40fa9ae7 Merge branch 'bugfix' 2021-11-20 13:22:37 -05:00
Stefan Kangas c5d6656328 Backport commit 42d4e24ff from Emacs
; Fix typos
42d4e24ff3f13ccbd401d93d70ecdee99b88a26d
Stefan Kangas
Fri Nov 12 13:59:58 2021 +0100
2021-11-20 13:03:45 -05:00
Bruce D'Arcus 30dbfc6cf1
org-manual: minor org-cite additions
* doc/org-manual.org (Handling citations): Add note and example to load
a processor package, and on the PRINT_BIBLIOGRAPHY keyword.
2021-11-18 16:07:07 +08:00
Juan Manuel Macías 85998490d9 ox-latex: add `options' latex attribute to tables
* lisp/ox-latex.el (org-latex--org-table): The `:options' LaTeX
attribute allows adding an optional argument (`\begin{env}[opt]'),
since certain tabular environments, such as `longtblr', accept optional
arguments.
* doc/org-manual.org (Tables in LaTeX export): this feature in the manual.
* etc/ORG-NEWS (New :options attribute when exporting tables to
LaTeX): this feature in `ORG-NEWS'.
2021-11-06 14:50:27 +01:00
Kyle Meyer 0a21425c84 Merge branch 'bugfix' 2021-11-01 20:52:23 -04:00
Hanno Perrey e7085eaa57 Backport commit f1c928637 from Emacs
* doc/org-manual.org (Templates in contexts): Add missing parenthesis to
code example for org-capture template contexts as documented in
docstring.

; * doc/misc/org.org: fix capture context example
f1c9286376d570e898d349200412021fd67e13d2
Hanno Perrey
Sun Oct 31 16:23:41 2021 +0100
2021-11-01 20:46:17 -04:00
Marco Wahl 7810804222 Merge branch 'bugfix' into main 2021-10-18 15:13:27 +02:00
Marco Wahl 37791bb4fc org-manual: Fix one kindex entry
Reminder: the kindex can be accessed via key "i" in info.  This fixes
also the pdf generation.
2021-10-18 15:09:58 +02:00
Nicolas Goaziou 08e9d34907 Merge branch 'bugfix' 2021-10-08 22:42:49 +02:00
Nicolas Goaziou f7fb7a3cf2 manual: Additional fixes to citations
* doc/org-manual.org (Citations): Mention binding for
`org-cite-insert'.  Fix spacing using non-breaking spaces.  Revert
some code uses introduced in the previous commit.
2021-10-08 22:40:23 +02:00
Nicolas Goaziou b06c6c7e78 org-manual: Typography fixes
* doc/org-manual.org (Citation export processors): Use fixed-with
areas for single-line examples.  Upcase keywords.  External commands
or symbols use code instead of verbatim.  Remove indentation when
appropriate.
2021-10-08 22:36:59 +02:00
Nicolas Goaziou 002a07b391 org-manual: Typography fixes
* doc/org-manual.org (Citation export processors): Use fixed-with
areas for single-line examples.  Upcase keywords.  External commands
or symbols use code instead of verbatim.  Remove indentation when
appropriate.
2021-10-08 22:23:33 +02:00
Nicolas Goaziou 1b56c2842d Merge branch 'bugfix' 2021-10-06 14:29:54 +02:00
Kyle Meyer 6874af8724 manual: Drop keybinding for org-table-blank-field
* doc/org-manual.org (Re-aligning and field motion): Update for
keybinding removal.

The keybinding was removed in 0c4e844c8 (Remove default binding for
org-table-blank-field, 2021-04-28).
2021-10-05 23:17:18 -04:00
Kyle Meyer 06578d7450 Merge branch 'bugfix' 2021-10-02 13:48:07 -04:00
Kyle Meyer e8b1aedff2 doc/doc-setup.org: Absorb header from Emacs repo
In the Emacs repository, this file's header was updated in include
copyright information in b3d310fa96 (Fixes for doc/misc org source
files, 2021-02-26).  Copy it over.
2021-10-02 13:35:46 -04:00
Bastien a46cf533fa Revert "org-manual.org: Another way to run version from git"
This reverts commit aaa184f766.
2021-10-02 19:20:39 +02:00
Max Nikulin aaa184f766 org-manual.org: Another way to run version from git
* doc/org-manual.org (Using Org's git repository): Suggest '-L' command
line option to test git version without modification of init file.
2021-10-02 19:17:15 +02:00
Max Nikulin 50e6ccff3a org-manual.org: Mention org-contrib NonGNU ELPA package
* doc/org-manual.org (Installing Org's contributed packages): Add a link
to the NonGNU ELPA package as an option to install org-contrib.  Mention
the list of external packages on Worg.
2021-10-02 19:17:14 +02:00
Max Nikulin 749368f4f0 org-manual.el: Restore `load-path' for git version
* doc/org-manual.org (Using Org's git repository): Add example of
`load-path' adjustment that was earlier in the previous section
and was removed by commit f9cdda8234, so 'above' became a dangling
reference.
2021-10-02 19:17:12 +02:00
Bastien 73875939a8 doc/Makefile: Also make orgguide.html 2021-09-29 15:06:08 +02:00
Bastien 33799db8c2 doc/org-manual.org: End sentences with two spaces, fix indentation 2021-09-29 13:04:10 +02:00
Juan Manuel Macías 6dcddb1b6f doc/org-manual.org: Fix Shakespeare's sonnet
* doc/org-manual.org (Verse blocks in LaTeX export): The previous
version of Shakespeare's sonnet is replaced by the version included in
Wikipedia (Shakespeare, William. Duncan-Jones, Katherine. Shakespeare’s
Sonnets. Bloomsbury Arden 2010. p. 113).
* etc/ORG-NEWS (Support verse blocks in LaTeX export): The last
sentence is superfluous.  There is no explanation below.
2021-09-29 13:00:24 +02:00
András Simonyi 158332224d doc/org-manual.org: Remove a couple of stray words
* doc/org-manual.org (Citation handling): Remove a pair of unnecessary words.
2021-09-29 08:55:58 +02:00
Kyle Meyer d4105060d2 orgcard.tex: Use en-dash for copyright years
This matches what's in the Emacs tree (and generated automatically by
admin/update-copyright).
2021-09-29 00:15:06 -04:00
Bruce D'Arcus 3b4ab1c3e4 doc/org-manual.org (Citations): Enhance
* doc/org-manual.org (Citations): Enhance.

This is based on a preliminary draft provided by Emmanuel Charpentier.
2021-09-28 06:59:20 +02:00
Max Nikulin 09dc3fa304 org-protocol.el: decode "+" in query part as space
* lisp/org-protocol.el (org-protocol-convert-query-to-plist):
Replace "+" chars by spaces before passing parameter string
to decoder.  Allow making org-protocol URIs with help of URLSearchParams
JavaScript class.
* lisp/org-protocol.el doc/org-manual.org etc/ORG-NEWS: Add examples
demonstrating new opportunity for browser bookmarklets.

Make parsing of URI parameters a bit closer to URL standard
https://url.spec.whatwg.org/#urlencoded-parsing
2021-09-27 17:50:49 +02:00
Bastien 4594423811 doc/org-manual.org: Fix typo
* doc/org-manual.org (Citation handling): Fix typo.
2021-09-27 14:32:52 +02:00
Bastien 177745e4c9 doc/org-manual.org (Citations handling): New section
* doc/org-manual.org (Citations handling): New section.
2021-09-27 12:15:43 +02:00
Bastien 2db02f9931 Merge branch 'bugfix' 2021-09-27 12:02:40 +02:00
Bastien 529a1bd829 doc/org-manual.org: Reintroduce lost footnote definition.
* doc/org-manual.org (Footnotes): Reintroduce lost footnote
definition.

Reported-by: Tim Landscheidt <tim@tim-landscheidt.de>
<https://list.orgmode.org/877dhx2qzj.fsf@vagabond.tim-landscheidt.de/>
2021-09-27 12:01:07 +02:00
Daniel Fleischer 7d67719d68 org-manual: comment about latex code-block export
* doc/org-manual.org: when using the latex Minted package, one needs to
set the '-shell-escape' flag in 'org-latex-pdf-process'.

Signed-off-by: Daniel Fleischer <danflscr@gmail.com>
2021-09-27 11:59:33 +02:00
Thomas S. Dye 45a5f17add org-manual.org: Augment TODO keywords example 2021-09-25 15:57:47 +02:00
Bastien e64d5bcc61 Merge branch 'bugfix' 2021-09-25 15:18:38 +02:00
TEC 4a11766cac docs: Update outdated code.orgmode.org links
* CONTRIBUTE, docs/org-manual.org, docs/ORG-NEWS: Replace mentions
of https://code.orgmode.org with references to the new repository
on Savannah (https://git.savannah.gnu.org).
2021-09-25 15:13:25 +02:00
Marco Wahl 4271f228db org-manual: Undo the last change in Shakespeare's verse
See commit 215d80d02b.
2021-09-20 12:09:31 +02:00
William Denton d700c036ba
org-manual: Add referring to tables in other files
* doc/org-manual.org (Passing arguments): Note
the other-file.org:example-table syntax.

TINYCHANGE
2021-09-19 21:35:36 +08:00
Daniel Fleischer 6600dc096d
org-manual: added section about regexps
* doc/org-manual.org: Inform users than regexps in Org are Elisp regular
expressions, so we add a short section linking to the relevant info node
and put some links to this new section in places where regexp are
presented.

Signed-off-by: Daniel Fleischer <danflscr@gmail.com>
2021-09-17 18:14:32 +08:00
Stefan Kangas 215d80d02b
Fix a small number of typos 2021-09-17 17:01:57 +08:00
Bastien 72af213be8 Merge branch 'maint' 2021-09-12 18:07:13 +02:00
Bastien 4be129f543 doc/Makefile: Clean up *.info files too
Continue 9802877fb by cleaning up *.info files and removing
duplicate *.html pattern.
2021-09-12 18:05:37 +02:00
Marco Wahl b4e575ee87 org-manual/guide: use function quotes for hooks and key-bindings 2021-08-31 23:04:49 +02:00
Yasushi SHOJI ebba483cf9
org-manual: Document the option 'none' for :results handling
The commit d4b739fbf2 added the "none" header argument but didn't
add it to the manual.  Document it in the manual so that users can
discover it.

Signed-off-by: Yasushi SHOJI <yashi@spacecubics.com>
2021-08-31 21:40:51 +08:00
Yasushi SHOJI 3b79fe1c00
org-manual: Move the default result handing at the top
`replace` is the default option for the :results header option for the
source blocks.  Move it to the top of the list.

Signed-off-by: Yasushi SHOJI <yashi@spacecubics.com>
2021-08-31 21:40:50 +08:00
Jorge P. de Morais Neto 09cf4a075e manual: Improve organisation of a section.
* doc/org-manual.org (Tracking TODO state changes): Move sentence.

The sentence was misplaced, interrupting the train of thought.  I also
did not understand the need for disabling paragraph indentation, so I
removed the directive.
2021-08-11 22:45:47 +02:00
Greg Minshall c34aae1d6b doc/Makefile: cleanall target now deletes doc/{org,orgguide}.texi
* doc/Makefile: `cleanall` target now deletes doc/{org,orgguide}.texi

In the past, at least one of these seems to have been a tracked
(source?) file.  That is no longer the case.
2021-05-29 22:36:08 +02:00
Juan Manuel Macias f4aac6090d ox-latex: add LaTeX attributes to quote block
* doc/org-manual.org (Quote blocks in LaTeX export): manual updated
* etc/ORG-NEWS (Support quote blocks in LaTeX export): news updated
* lisp/ox-latex.el (latex): add `org-latex-default-quote-environment' to `:options-alist'
(org-latex-default-quote-environment): the default quote environment
is `quote'
(org-latex-quote-block): add two attributes: `environment' and `options'
2021-05-29 22:21:59 +02:00
Nicolas Goaziou 846801e82c manual: More capitalization
* doc/org-manual.org (Verse blocks in LaTeX export): This is
a follow-up to last commit.
2021-05-20 15:57:16 +02:00
Nicolas Goaziou 7ca7d8dd18 manual: Fix capitalization of "ATTR_LATEX"
* doc/org-manual.org (Verse blocks in LaTeX export): Do not use fancy
"ATTR_LaTeX" syntax.  Preferred syntax in Org Documents is
"attr_latex", but it is capitalized here for emphasis.
2021-05-20 15:53:29 +02:00
Bastien 4362b93018 Merge branch 'maint' 2021-05-16 10:36:42 +02:00
Bastien 9802877fbe doc/Makefile: Use the .info extension for org.info and orgguide.info
* doc/Makefile (install): Use the .info extension when generating
info files (org.info and orgguide.info).
2021-05-16 10:36:02 +02:00
Juan Manuel Macías 91373e15c8 ox-latex.el: Support specific attributes for verse block
* lisp/ox-latex.el (org-latex-verse-block): Support verse-specific
attributes.

* doc/org-manual.org (Verse blocks in LaTeX export): New section.

Link: https://orgmode.org/list/874kfdn0k5.fsf@posteo.net/
2021-05-15 16:13:49 +02:00
Adam Spiers 33027f992d New command `org-refile-reverse' bound to C-c C-M-w
* lisp/org-refile.el (org-refile-reverse): New command.

* lisp/org-keys.el (org-mode-map): Bind C-c C-M-w to
`org-refile-reverse'.

* doc/org-manual.org (Refile and Copy): Document
`org-refile-reverse'.

* etc/ORG-NEWS (New command ~org-refile-reverse~ (=C-c C-M-w=)):
Announce the new command.

Link: https://orgmode.org/list/20200830001047.21362-1-orgmode@adamspiers.org/
2021-05-15 16:13:49 +02:00
Bastien 97d9460945 Merge branch 'maint' 2021-05-07 07:18:16 +02:00
Bastien 4d26075039 doc/org-manual.org (Features Overview): Fix typo
* doc/org-manual.org (Features Overview): Fix typo.

Reported-by: Ian Nehera <delta29@shaw.ca>
2021-05-07 07:17:48 +02:00
Bastien bee8e3adf8 Merge branch 'maint' 2021-05-06 12:13:04 +02:00
Bastien 15200c25d5 doc/org-manual.org: Small rephrasing
* doc/org-manual.org (Features Overview): Small rephrasing.

Reported-by: Ian Nehera <delta29@shaw.ca>
Link: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=47738
2021-05-06 12:10:25 +02:00
Bastien 4b553e5d70 doc/org-manual.org (List of Contributions): Add Timothy E Chapman
* doc/org-manual.org (List of Contributions): Add Timothy E Chapman.
2021-05-05 13:56:05 +02:00
Bastien 7c0c9a2b88 doc/org-manual.org: Add Kyle Meyer and Ihor Radchenko
* doc/org-manual.org (List of Contributions): Add Kyle Meyer and
Ihor Radchenko.
2021-05-05 09:40:11 +02:00
Bastien d48276b894 Replace org-speed-commands-user' by org-speed-commands'
* etc/ORG-NEWS: Announce `org-speed-commands'.

* doc/org-manual.org (Speed Keys): Document `org-speed-commands'
instead of `org-speed-commands-user'.

* lisp/org-compat.el (org-speed-commands-user): Make an obsolete
variable.

* lisp/org-keys.el (org-speed-commands-user): Remove.
(org-speed-commands): Rename from `org-speed-commands-default' and
make a defcustom.  Add the docstring of `org-speed-commands-user'.
(org-speed-command-help): Throw a message about obsolete option
`org-speed-commands-user' when set in the user configuration.
(org-speed-command-activate): Update docstring.

Link: https://orgmode.org/list/87eeep3c1u.fsf@bzg.fr/
2021-05-03 16:30:04 +02:00
Eric S Fraga 479a3da22e org-manual.org: describe external reference for :var header
* org-manual.org: the description of the :var header argument for
working with source code has been expanded to mention the possibility
of having an external reference, a reference to an element in another
file.
2021-05-03 15:00:14 +02:00
Bastien 678cb68f78 doc/*: Update references to the old contrib/ directory
* doc/org-manual.org (Installing Org's contributed packages)
(Feedback, External Links, TODO dependencies)
(Capturing column view, Exporting, Add-on Packages)
(List of Contributions, Footnotes): Update references to the old
contrib/ directory.

* doc/org-guide.org (Installation): Ditto.
2021-05-03 13:12:36 +02:00
Gustavo Barros e8562a3327 date/time prompt: Provide support for HHhMM time input
* lisp/org.el (org-read-date-analyze): Add support for HHhMM time
input, in similar way as for am/pm times.
* doc/org-manual.org (The date/time prompt): Add example to illustrate
the feature.

TINYCHANGE
2021-05-01 17:40:17 +02:00
Bastien Guerry 611e806ef9 doc/org-manual.org: Document the new property :refile-targets
* doc/org-manual.org (Template elements): Document the new
property :refile-targets.
2021-05-01 13:12:44 +02:00
Bastien Guerry f9cdda8234 doc/org-manual.org: Deprecate installation thru Org ELPA or archives
* doc/org-manual.org (Installation): Do not document installation
through Org ELPA or an archive as these installation methods will
become obsolete after Org 9.5.
2021-04-28 09:40:01 +02:00
Cheong Yiu Fung bd267679c6 manual: Add hints for visible-only export
* doc/org-manual.org (The Export Dispatcher): Add a reference to
sparse trees, which may come handy when exporting only visible part of
the buffer.
2021-04-27 22:29:58 +02:00
Bastien Guerry 31d48755bf Merge branch 'maint' 2021-04-27 09:43:11 +02:00
Bastien Guerry 13a1a4fb96 Be more consistent about treating tags as case-sensitive
* lisp/org-agenda.el (org-agenda-finalize):
(org-agenda-format-item): Do not downcase tags.
(org-downcase-keep-props): Remove unused function.
(org-agenda-filter-expand-tags): Do not case-fold search.

* lisp/org.el (org-tags-expand): Document `downcased' argument as
obsolete and do not allow to expand downcased tags.

* testing/lisp/test-org.el (test-org/tags-expand): Remove test for
downcased tags expansion.

* doc/org-manual.org (TODO keywords, tags, properties, etc.):
Suggest that user-defined are usually lowercase, but don't make it
a requirement.

Reported-by: David Masterson <dsmasterson92630@outlook.com>
Link: https://orgmode.org/list/SJ0PR03MB5455D8D0C4F71AA495A9ABF79B709@SJ0PR03MB5455.namprd03.prod.outlook.com/
2021-04-27 09:41:26 +02:00
Kyle Meyer c93066d8e2 Merge branch 'maint' 2021-04-26 23:01:06 -04:00
Kyle Meyer 37f291ac08 guide: Fix kbd syntax
* doc/org-guide.org (HTML Export): Fix kdb syntax.
2021-04-26 22:52:16 -04:00
Cheong Yiu Fung 58cacdf0e0 org-manual.org: Fix syntax
* doc/org-manual.org (HTML export commands): Fix kbd representation.

TINYCHANGE
2021-04-26 22:52:06 -04:00
Gustav Wikström 3d52843269 Org-id: Clarify customization documentation for org-id, ts option
* lisp/org-id.el (org-id-ts-format, org-id-method): Clarify docstrings.
* doc/org-manual.org (Handling Links): Mention org-id-method in
the manual.
2021-04-19 22:55:48 +02:00
Nicolas Goaziou edadbb8bab Merge branch 'maint' 2021-04-19 10:09:04 +02:00
Erik Hetzner f6eca6505d manual: Fix publish options
* doc/org-manual.org (Publishing sample configuration):
* doc/org-guide.org (Publishing):
Fix stylesheet setting in publish: :style is not a valid option; use
:html-head instead. :table-of-contents is not a valid option; use
:with-toc instead. :publishing-function is required.
2021-04-19 10:08:37 +02:00
Nicolas Goaziou 949270d4bf Merge branch 'maint' 2021-04-19 01:10:20 +02:00
Nicolas Goaziou 140df469ed manual: Remove date keyword
* doc/org-manual.org: Remove date keyword.

It uses an invalid macro call.  Also, Texinfo export does not support
date keyword anyway.
2021-04-19 01:08:59 +02:00
Nicolas Goaziou e4f4a153df Merge branch 'maint' 2021-04-18 11:56:48 +02:00
Jorge P. de Morais Neto d317d77d8e manual: Fix typo about org-latex-images-centered
* doc/org-manual.org (Images in LaTeX export): Fix typo about
org-latex-images-centered.
2021-04-18 11:56:20 +02:00
Kyle Meyer 4d9dabc36f Merge branch 'maint' 2021-03-29 00:34:15 -04:00
Maxim Nikulin 4de2fff87d Add quotes to emacsclient arguments in examples
* doc/org-manual.org:
* lisp/org-protocol.el: Quote emacsclient arguments
in examples to prevent interpreting of ampersands as intent
to run processes in background by bash and similar shells.
Single quotes may cause a problem with cmd.exe, so use
double quotes despite they are a bit less safe in bash and Co.
2021-03-29 00:32:29 -04:00
Maxim Nikulin a17243f9a5 org-manual.org: Fix typo in org-protocol capture example
* doc/org-manual.org: Use "&" as parameter separator in query part
of example for org-protocol capture URI.
2021-03-29 00:32:29 -04:00
Kyle Meyer 68db6fc064 Merge branch 'maint' 2021-03-25 00:53:11 -04:00
Kyle Meyer 4f98c86b3b manual: Grammar fix
* doc/org-manual.org (Publishing action): Fix conjugation.
2021-03-24 22:24:59 -04:00
Greg Minshall d156399445 Update example :publishing-function names in manual
* doc/org-manual.org (Publishing action): Fix references to
org-latex-publish-to-pdf and org-org-publish-to-org.
2021-03-24 22:24:55 -04:00
Stefan Kangas 2e1c984153 Prefer HTTPS to HTTP in most links 2021-03-21 15:21:22 -04:00
Stefan Kangas 8cc992f7b2 Prefer HTTPS to HTTP for links to gnu.org 2021-03-21 14:29:13 -04:00
Kyle Meyer be35212683 Merge branch 'maint' 2021-03-16 23:52:34 -04:00
Kyle Meyer e07cb2ad3c manual: Fix org-latex-listings reference in footnote
* doc/org-manual.org (Footnotes): Refer to org-latex-listings instead
of org-export-latex-listings.

The last occurrence of org-export-latex-listings was deleted with the
contrib/oldexp/ removal in Org 8.
2021-03-16 23:52:09 -04:00
Stefan Monnier 129c33dddf * lisp/org-agenda.el: Use lexical-binding
- Removed the global (defvar date) and (defvar entry) so as not to
  conflict with function arguments of that name.  Instead I added such
  `defvar`s in the body of each of the functions where it
  seemed needed.
- I added some FIXMEs for some issues I found along the way.
- Added an `org-dlet` macro, just like I had done for `calendar-dlet`,
  but I also use `defvar` "manually" at some places, when splitting an
  existing `let` into a mix of `let`s and `dlet`s seemed too much trouble.
- Removed uses of `org-let and `org-let2` not only because I consider
  them offensive to my sense of aesthetics but also because they're
  basically incompatible with lexical scoping.
  I replaced them with uses of `cl-progv` which are a bit more verbose.
  Maybe we should define some `org-progv` macro on top of `cl-progv` to
  make the code less verbose, but I didn't do that because I like the
  fact that the current code makes uses of `eval` a bit more obvious
  (since these behave differently with lexical scoping than with
  lexical binding, it seemed worthwhile).
- Removed the use of `eval` in `org-store-agenda-views` which was only
  placed there in order to use a macro before it's defined (it would
  have been simpler/cleaner to just move that functions *after* the
  macro, but with the new code the problem doesn't occur any more anyway).
- Replaced a few `(lambda...) with actual closures.

Detailed changes follow:

(date, entry): Don't declare as being globally dynbound.
(org-agenda-format-date-aligned): Remove unused var `weekyear`.
(org-agenda-mode): `run-mode-hooks` is always available nowadays.
(org-agenda-undo): Remove unused var `last-undo-buffer`.
(org-agenda): Rename arg to `keys` and then dyn-bind it as `org-keys`.
Remove unused vars `buf` and `key`.
(org-agenda): Use `pcase` and `cl-progv` instead of `org-let`.
(org-let, org-let2): Mark as obsolete.
(org-agenda-run-series): Use `cl-progv` instead of `org-let` and `org-let2`.
(org-agenda-run-series): New function.
(org--batch-agenda): New function extracted from `org-batch-agenda`.
(org-batch-agenda): Use it.
(org--batch-agenda-csv): New function extracted from `org-batch-agenda-csv`.
(org-batch-agenda-csv): Use it.
(org--batch-store-agenda-views): New function, extracted from
`org-batch-store-agenda-views`.
(org-store-agenda-views, org-batch-store-agenda-views): Use it.
(org--batch-store-agenda-views): Use `cl-progv` instead of
`org-eval-in-environment`.
(org-agenda-write): Use `cl-progv` instead of `org-let`.
Use `with-current-buffer`.
(org-agenda-filter-any): Use `cl-some` instead of `eval`.
(org-agenda-list): Remove unused var `e`.
(org-search-view): η-reduce.
(crm-separator): Declare var.
(org-agenda-skip-if): Remove unused var `beg`.
(org-agenda-list-stuck-projects): Use a closure rather than `(lambda..).
(diary-modify-entry-list-string-function, diary-file-name-prefix)
(diary-display-function): Declare vars.
(org-diary): Declare `date` and `entry` as dynbound.
(org-agenda-get-day-entries): Use `org-dlet`.
(org-agenda-get-timestamps, org-agenda-get-progress)
(org-agenda-get-deadlines, org-agenda-get-scheduled, org-agenda-get-blocks):
Declare `date` as dynbound.
(org-agenda-get-sexps, org-class): Declare `date` and `entry` as dynbound.
(org-agenda-format-item): Declare the vars mentioned in
`org-compile-prefix-format` as dyn-bound.
Also binding `extra`, suggested by Kyle Meyer <kyle@kyleam.com>.
(org-compile-prefix-format): Remove unused var `e`.
Use `member` rather than or+equal.
(org-set-sorting-strategy): Minor simplification.
(org-entries-lessp): Use `org-dlet`.
(org-agenda-redo): Declare var `org-agenda-tag-filter-while-redo`.
(org-agenda-redo): Use `cl-progv` rather than `org-let`.
(org-agenda-filter): Remove unused var `rpl-fn`.
Use `org-pushnew-to-end` to replace `add-to-list` on lexical var.
(org-agenda-filter-by-tag): Remove unused var `n`.
(org-agenda-filter-apply): Use `org-dlet`.
(org-agenda-compute-starting-span): Remove unused var `dg`.
(org-agenda-forward-block): Remove unused var `pos`.
(org-archive-from-agenda): Declare var.
(org-agenda-refile): Remove unused var `pos`.
(org-agenda-headline-snapshot-before-repeat): Declare var.
(org-agenda-todo): Remove redundant use of `bound-and-true-p`.
(org-agenda-add-note): Remove unused var `hdmarker` and unused `arg`.
(org-agenda-change-all-lines): Remove unused var `pl`.
(org-agenda-priority): Remove unused var `marker`.
(org-agenda-set-effort): Remove unused var `newhead`.
(org-agenda-schedule): Remove unused var `type`.
(org-agenda-clock-cancel): Remove unused `arg`.
(org-agenda-execute-calendar-command): Use `org-dlet`.
(org-agenda-bulk-action): Use closures instead of `(lambda ...).
(org-agenda-show-the-flagging-note): Remove unused vars `heading` and
`newhead`.
(org-agenda-remove-flag): Avoid `setq`.

* testing/org-test.el (org--compile-when): New macro.
(org-test-jump): Use it so compilation doesn't fail or generate broken
code when `jump` is not available.

* testing/lisp/test-org-src.el:
* testing/lisp/test-org-attach.el:
* testing/lisp/test-org-agenda.el:
* testing/lisp/test-ob-java.el: Pass explicit filename to `require`
so as not to rely on ".../testing" being in `load-path` during compilation.

* lisp/org-num.el: Require` org`.

* lisp/org-macs.el (org-eval-in-environment): Declare obsolete.
(org-dlet, org-pushnew-to-end): New macros.

* doc/Makefile (org.texi, orgguide.texi, %_letter.tex): Simplify quoting.

* contrib/lisp/ob-sclang.el: Don't crash compilation when `sclang`
is not available.

* contrib/lisp/ob-clojure-literate.el: Don't crash compilation when `cider`
is not available.

* contrib/lisp/ob-arduino.el: Don't crash compilation when `arduino-mode`
is not available.

* .gitignore: Add files generated during `make packages/org`.
2021-03-09 22:56:33 -05:00