* lisp/org-compat.el (version<): Use stub version of
`combine-change-calls' when it does not exist yet in Emacs or when it
is known to have a critical bug. Use `org-combine-change-calls'
instead of overwriting the macro system-wide.
* lisp/org-footnote.el (org-footnote-sort):
* lisp/org.el:
(org-demote-subtree):
(org-paste-subtree): Use the new macro name.
Reported-by: Alain.Cochard@unistra.fr
Link: https://orgmode.org/list/87ilhq74j8.fsf@localhost
* ob-sql.el (org-babel-find-db-connection-param): read
sql-connection-alist like sql.el/sql-connect and allow strings.
Signed-off-by: Andreas Gerler <baron@bundesbrandschatzamt.de>
* lisp/org-element.el: Query cache variables from the base buffer.
They are only kept up-to-date there.
* testing/lisp/test-org.el (test-org/map-entries): Add test.
Reported-by: Hanno Perrey <hanno@hoowl.se>
Link: https://orgmode.org/list/87pmau4fi3.fsf@hoowl.se
* lisp/org-element.el (org-element-cache-map): Never map over element
starting before the point manually moved (or set via
`org-element-cache-map-continue-from') by FUNC.
* testing/lisp/test-org.el (test-org/map-entries): Add tests.
Reported-by: Matthieu Caneill <matt@brokenwa.re>
Link: https://orgmode.org/list/Y9MKUzWWbErLFhmq@brokenwa.re
* lisp/org-macs.el (org-assert-version): Explicitly state that Org
loading is aborted. Some users otherwise assume that the warning can
be ignored. Also, remove sentence about `load-path' as it is
explained later in the warning text.
* lisp/org-agenda.el (org-fix-agenda-info): Do not use `string-pad'
that is only available since Emacs 28. Instead, use the expression
used as default value of `calendar-iso-date-display-form'.
Reported-by: Aaron L. Zeng <me@bcc32.com>
Link: https://orgmode.org/list/20230124025259.1301063-1-me@bcc32.com
* testing/lisp/test-ob-octave.el (ob-octave/graphics-file):
(ob-octave/graphics-file-session): Do not assert that octave must not
emit warnings. Just test the file created by side effect.
We currently have no reliable way to disambiguate warnings from
non-zero exit code when using `org-babel-eval'. Warnings are ok, as
long as they do not result in the file not being created in the test.
Link: https://orgmode.org/list/87mt6m5n6u.fsf@localhost
* lisp/org-persist.el: Bind pp-use-max-width to silence byte-compiler
warning about unused lexical variable.
Note that loading pp.el upfront rather than relying on the pp function
being autoloaded would also eliminate the warning, but that would only
work on Emacs 29 or later because earlier versions do not have the
pp-use-max-width option.
; Fix typos
920a7d38e96134289393b7bfcc3a7b88be73925b
Stefan Kangas
Sun Jan 15 02:14:19 2023 +0100
[km] These were likely not typos but intended as an abbreviation for
"if and only if". However, using "if" works fine in these spots,
so let's just go along with the change. (These may end up being
reverted on Emacs's side; see emacs-devel
<83a62k72lx.fsf@gnu.org>, 01-15.)
* lisp/org-table.el (org-table-blank-field):
(org-table-clean-line): Avoid `org-string-width' modifying match data.
As long as `org-string-width' creates a new window buffer, third-party
modes and Emacs distributions might modify the match data in buffer
hooks. Hence, we cannot assume that match data is not modified even
though `org-string-width' code itself does not alter the match data.
Note: Adding `save-match-data' around function calls is generally a
good practice when the surrounding code relies on the match data being
intact. Elisp conventions don't prohibit functions to modify match
data without notice in their docstring.
Reported-by: Thomas Schneider <qsx@chaotikum.eu>
Link: https://orgmode.org/list/wwufsc7edzu.fsf@chaotikum.eu
* lisp/ob-core.el (org-babel-temporary-stable-directory): Use
`temporary-file-directory' variable instead of function. The function
returns value depending on the `default-directory' at Org startup time
thus creating unpredictable temporary babel locations that may
sometimes litter current directory.
Reported-by: bhrgunatha <bhrgunatha@gmail.com>
Link: https://orgmode.org/list/93b040e1-6dc6-487f-de89-a4cea9a560ff@gmail.com
Load org-element for agenda instead of relying on org-element being
loaded when agenda is ran.
Reported-by: zimoun <zimon.toutoune@gmail.com>
Link: https://orgmode.org/list/86r0vszn3w.fsf@gmail.com
* doc/org-manual.org (Weekly/daily agenda):
* lisp/org-agenda.el (org-agenda-start-on-weekday):
(org-agenda-start-day): Document that `org-agenda-start-on-weekday'
takes precedence over `org-agenda-start-day' when agenda span is 7 or
14 days.
Reported-by: Eppo Math <eppolito.math@gmail.com>
Link: https://orgmode.org/list/878ri67plt.fsf@localhost
* lisp/org-fold-core.el (org-fold-core--isearch-show): Make sure that
the actual isearch match is revealed. This relies on undocumented
behavior of isearch that point is at the match when
'isearch-open-invisible is called.
(org-fold-core-region): Disable 'isearch-open-invisible-temporary
features when `org-fold-core-style' is 'overlays. This is to work
around the undocumented requirement of isearch to _not_ delete the
overlay passed to 'isearch-open-invisible-temporary function. Since
`org-fold-show-set-visibility' may destroy overlays arbitrarily, we
cannot currently support isearch `org-fold-show-context-detail' in
full.
Reported-by: Matt Lundin <mdl@imapmail.org>
Link: https://orgmode.org/list/87zgb6tk6h.fsf@localhost
* lisp/org-element.el (org-element-fixed-width-interpreter): Interpret
fixed-width element with :value "" as ":\n", not as empty string.
* testing/lisp/test-org-element.el (test-org-element/fixed-width-interpreter):
Fixed the test.
The previous test, albeit intentionally asserting "" result, breaks
reversibility of parse-interpret sequence.
* testing/lisp/test-ob-octave.el (ob-octave/graphics-file):
(ob-octave/graphics-file-session):
(ob-octave/graphics-file-space): Wrap GET-BUFFER in BUFFER-LIVE-P.
This ensures that a killed buffer does not cause an incorrect failure
of a test.
Link: https://orgmode.org/list/87bknh5nva.fsf@localhost
* lisp/ob-shell.el (org-babel-shell-initialize): Do not search shell
name string by `eq' in `org-babel-shell-set-prompt-commands' alist.
Use `assoc' that is comparing by `equal' instead.
Reported-by: Matt <matt@excalamus.com>
Link: https://orgmode.org/list/87h6x8kluc.fsf@localhost
* lisp/org-persist.el (org-persist-unregister): Do not try to
normalize 'all ASSOCIATED. It is not a valid association that should
be handled specially. Previously, an error was thrown.
This reverts commit 10e857d428.
* lisp/ob-core.el:
(org-babel-merge-params):
(org-babel-process-params):
(org-babel-read):
* lisp/org-table.el: Add FIXME comments to places where arbitrary code
execution may happen.
The extra query is reverted until we develop a better code execution
safety system for Org. The commit introduced too many user queries,
making the whole idea of asking users to execute code from Org files
not useful.
Link: https://orgmode.org/list/878rinadlq.fsf@localhost
* lisp/org.el (org-mode): Do not suppress modification hooks when
aligning tables. Otherwise, cache state may become invalid.
Reported-by: Stefan <org@stefan.failing.systems>
Link: https://orgmode.org/list/87tu1wse45.fsf@localhost
Most copyright years were updated with the port of Emacs's cae528457
in e0815d754. Update the remaining copyright years for files that
have Free Software Foundation as the copyright holder but aren't
included in the Emacs repo.
* lisp/org-macs.el (org-assert-version): Make quoting "'" in the
message more readable.
Thanks to Stefan Monnier <monnier@iro.umontreal.ca> for the
suggestion.
* testing/lisp/test-ob-octave.el (ob-octave/graphics-file):
(ob-octave/graphics-file-session):
(ob-octave/graphics-file-space): Do not check the created image file
size. This tests causes race condition between the test and Octave
writing image to disk. Also, the correctness of image file is nothing
of Org's business as long as ob-ocatave's Elisp implementation is
concerned.