Commit Graph

15444 Commits

Author SHA1 Message Date
Nicolas Goaziou 73c0989037 Fix last commit 2019-08-24 22:58:29 +02:00
Nicolas Goaziou ed048fa83d Fix %start-line in `org-babel-tangle-comment-links'
* lisp/ob-tangle.el (org-babel-tangle-comment-links): %start-line
reports the line number, not the buffer position at the beginning of
line.

Reported-by: immanuel <immanuel.litzroth@gmail.com>
<http://lists.gnu.org/r/emacs-orgmode/2019-08/msg00267.html>
2019-08-24 22:44:18 +02:00
Nicolas Goaziou d64f7a2c9b Silence byte-compiler 2019-08-24 00:11:07 +02:00
Marco Wahl d83149bad1 org-agenda: Display duration of clocking without end time 2019-08-23 10:45:37 +02:00
Nicolas Goaziou 784adcd844 Do not pollute `narrow-map' keymap
* lisp/org-keys.el (org-map-map): Use `org-mode-map' instead of
`narrow-map'.

Reported-by: Omar Antolín Camarena <omar@matem.unam.mx>
<http://lists.gnu.org/r/emacs-orgmode/2019-08/msg00256.html>
2019-08-23 10:38:43 +02:00
Abhishek Chandratre c57f12b707 Fix org-store-link for eshell
lisp/ol-eshell.el (org-eshell-store-link): Replace `dired-directory'
variable with `eshell/pwd' function to find current directory.

During org-store-link `dired-directory' variable returns nil.
Thus replacing it with (eshell/pwd), which returns pwd.

TINYCHANGE
2019-08-22 19:11:04 +02:00
Nicolas Goaziou 4848b8b9aa ob: Preserve comma escaping when inserting results
* lisp/ob-core.el (org-babel-insert-result): Fix typo
* testing/lisp/test-ob.el (test-ob/preserve-comma-escape): New test.

Reported-by: "Berry, Charles" <ccberry@ucsd.edu>
<http://lists.gnu.org/r/emacs-orgmode/2019-08/msg00250.html>
2019-08-22 10:03:56 +02:00
Christian Dietrich a72466ce8d Fix bug in org-babel-tangle-file with symlinked files
Assume that there is file A and symlink B that points to file A. If
there is an open buffer that points to A and we
call (org-babel-tangle-file "B"), then this function kills the buffer
since get-file-buffer does not follow symlinks.
2019-08-22 09:50:26 +02:00
Carsten Dominik 96cc762ff3 Remove duplicate selection letters from tag filter prompt.
* lisp/org-agenda.el (org-agenda-filter-by-tag): Remove duplicate
selection letters from tag filter prompt.  If tag groups were the same
in multiple agenda files, the selection characters would be repeated
in the prompt.
2019-08-20 17:58:31 +02:00
Nicolas Goaziou f3474724ad ol: Allow [[\\\\]] links
* lisp/ol.el (org-link-make-regexps): Allow [[\\\\]] links.
2019-08-20 14:24:38 +02:00
Nicolas Goaziou 4f3d1eefbd Remove `org-enable-fixed-width-editor'
* lisp/org.el (org-enable-fixed-width-editor): Remove variable.
2019-08-19 12:22:22 +02:00
Kyle Meyer c7c04b0447 Merge branch 'maint' 2019-08-18 17:44:08 -04:00
Kyle Meyer 9e1b9fe627 Port more time-related changes
* lisp/org-agenda.el (org-agenda-check-clock-gap):
* lisp/org-clock.el (org-clock-get-clocked-time)
(org-clock-resolve-clock, (org-clock-resolve)
(org-resolve-clocks, org-resolve-clocks-if-idle)
(org-clock-in, org-clock-out, org-clock-sum, org-clocktable-steps):
* lisp/org-element.el (org-element-cache-sync-duration)
(org-element--cache-set-timer, org-element--cache-interrupt-p):
(org-element--cache-sync):
* lisp/org-habit.el (org-habit-insert-consistency-graphs):
* lisp/org-indent.el (org-indent-add-properties):
* lisp/org-timer.el (org-timer-start):
(org-timer-pause-or-continue, org-timer-set-timer):
* lisp/org.el (org-today, org-auto-repeat-maybe): Port time-related
changes from the Emacs repo by using compatibility wrappers.

In the Emacs repo, there has been a lot of changes to Org files
involving time-related code.  I've ported some of those changes but
have largely ignored any changes that break compatibility with older
Emacsen that we support.  That, however, isn't a good approach because
it will be hard to do a systematic update once we bump our minimum
Emacs requirement.  Instead use the recently added compatibility
wrappers where needed, which is ugly but more maintainable.

The main time-related changes this leaves unported are changes that
replace (apply #'encode-time args) calls with (encode-time args).
Until the first form is unsupported, adding a compatibility function
doesn't seem worth the churn.

Relevant Emacs commits include
c75f505dea6a560b825384cf3d277690f86840bf,
57c74793c46c6533b63836f00aecaf3ac2accb6d,
988e37fa0f922b852715671d59a0e3f682373411,
476066e89d6f0bb87220da690b8a476bf9655b80,
89c63b3522b62c0fd725f0b348927a2069238452.
2019-08-18 17:37:51 -04:00
Kyle Meyer d72b4af96e org-clock: Adjust steps calculation for Emacs 24 compatibility
* lisp/org-clock.el (org-clocktable-increment-day): Use
org-decode-time so that integer can be given for time on Emacs 24.
(org-clocktable-steps): Work with a float rather than internal time to
avoid "Invalid time specification" error on Emacs 24.

This fixes the failure of test-org-clock/clocktable/step on Emacs 24.
Note that the version of org-clocktable-steps on master has been
reworked and does not share this issue.
2019-08-18 17:36:13 -04:00
Kyle Meyer a23d0225ab org-time-stamp: Simplify encode-time call
* lisp/org.el (org-time-stamp): Use org-time-string-to-time.

This should have been applied with a6cead0d2 (Backport commit
476066e89 from Emacs, 2019-02-22).
2019-08-18 17:36:13 -04:00
Paul Eggert 74bf99502d Backport commit 988e37fa0 from Emacs
* lisp/org-agenda.el (org-agenda-get-timestamps, org-agenda-get-progress)
(org-agenda-show-clocking-issues):
* lisp/org-capture.el (org-capture-set-target-location):
* lisp/org-clock.el (org-clock-get-sum-start):
* lisp/org.el (org-current-time, org-store-link)
(org-read-date, org-read-date-display)
(org-display-custom-time, org-timestamp-to-time)
Simplify use of encode-time.
* lisp/org-clock.el (org-clock-in, org-clock-update-time-maybe):
* lisp/org-colview.el (org-columns--age-to-minutes):
* lisp/org-macs.el (org-2ft):
* lisp/org.el (org-get-scheduled-time, org-get-deadline-time)
(org-add-planning-info, org-time-string-to-absolute)
(org-closest-date):
Use org-time-string-to-time instead of doing it by hand with
encode-time.
* lisp/org.el (org-read-date): Avoid extra trip through encode-time.

Simplify use of encode-time
988e37fa0f922b852715671d59a0e3f682373411
Paul Eggert
Sun Feb 10 23:54:35 2019 -0800

Note(km): org-current-time has been modified to use org-time-subtract
and org-time-less-p for backward compatibility.  Some changes from
988e37fa0 have been dropped to keep encode-time's call compatible with
older Emacsen.
2019-08-18 17:36:13 -04:00
Paul Eggert a3fcf6dff4 Backport commit 3d1c9a77c from Emacs
* lisp/org-timer.el (org-timer-show-remaining-time):
Don’t assume the remaining time is less than one hour.
Simplify.  The simplification removes the need for a
decode-time, and fixes a typo I introduced recently.

Fix org-timer-show-remaining-time > 1 hour
3d1c9a77c52664c8c3e4fa1ae25e1d13aab9b2f9
Paul Eggert
Sat Aug 17 17:22:25 2019 -0700

Note(km): This replaces porting of Emacs's c90a420779 (Add FIXMEs for
subsecond support, 2019-08-17).  It's modified to use
org-time-subtract and org-time-convert-to-integer for backward
compatibility.
2019-08-18 17:36:13 -04:00
Kyle Meyer bdc5861cf7 org-compat: Add kludges for time-related functions
* lisp/org-compat.el (org-decode-time, org-format-time-string)
(org-time-add, org-time-less-p, org-time-since, org-time-subtract):
New compatibility functions.

On Emacs 24, these functions are stricter about what they accept for
time.  These new function will be used to port over changes in the
Emacs repo.  Don't bother doing a bulk substitution in existing Org
code because that would produce a lot of churn and these calls should
already be compatible with Emacs 24.
2019-08-18 17:36:12 -04:00
Kyle Meyer 24ba689506 org-compat: Add time-convert compatibility wrappers
* lisp/org-compat.el (org-time-convert-to-integer)
(org-time-convert-to-list): New defsubt's to replace common
invocations of time-convert (new in Emacs 27).
* lisp/org-compat.el (org-current-time-as-list): Drop in favor of
org-time-convert-to-list.

These will be used to port changes from the Emacs repo.
2019-08-18 17:31:05 -04:00
Nicolas Goaziou 3405b9afac Hide newly created properties drawers
* lisp/org.el (org-flag-drawer): Change signature.
(org-insert-property-drawer): Hide newly created properties drawers.
2019-08-17 17:47:01 +02:00
Kyle Meyer 4e3a1b3f5a org-compat: Move proper-list-p kludge to proper section 2019-08-17 09:54:35 -04:00
Kyle Meyer 531f4be256 org-compat: Define org-xor as alias for xor if available
* lisp/org-macs.el (org-xor): Move to ...
* lisp/org-compat.el (org-xor): ... here, making it an alias for xor
on Emacs 27.

This is an alternative to porting Emacs's
c676444a43e4634c1f98ec286b5bd9e46b23216b, which targets the code prior
to 45a1918ef (Move `org-xor' into "org-macs.el", 2017-10-17).
2019-08-17 09:54:32 -04:00
Paul Eggert 218e694964 Backport commit c6ba8100e from Emacs
* lisp/org-id.el (org-id-time-to-b36):
Remove unnecessary ‘or’.

Fix minor Org timestamp inefficiencies
c6ba8100ea1db4616d3fe8485430b29143bc3d2e
Paul Eggert
Mon Aug 5 17:38:15 2019 -0700
2019-08-17 09:45:22 -04:00
Paul Eggert 08c7bbbf71 Backport commit a5b796a87 from Emacs
* lisp/ob-haskell.el (org-babel-haskell-export-to-lhs):
Omit unnecessary ‘?’ after nullable pattern.
* lisp/org-capture.el (org-capture-fill-template):
Match upper-case as well as lower-case letters.

Fix 2019-08-04 regex lint
a5b796a8798a809044d847568e6472cc5eca077e
Paul Eggert
Sun Aug 4 11:39:54 2019 -0700
2019-08-17 09:45:22 -04:00
Paul Eggert 71ce18920a Backport commit 5f3f3884a from Emacs
Improve time function doc
5f3f3884a0d2a88101d330b82ef5b584cfc02aa6
Paul Eggert
Sun Aug 4 10:09:25 2019 -0700
2019-08-17 09:45:22 -04:00
Basil L. Contovounesios 765577d9b3 Backport commit 2267110b6 from Emacs
* lisp/ob-exp.el (org-babel-exp-process-buffer):
* lisp/org-agenda.el (org-agenda-show-new-time):
Always pass an explicit plist to remove-text-properties.

Fix usage of remove-text-properties
2267110b6f00bbb0ad87f4621e6ecd9dc1bd8581
Basil L. Contovounesios
Thu Aug 1 17:04:53 2019 +0300
2019-08-17 09:45:22 -04:00
Eric S Fraga cfe4598aa1 Add split-window-right option for editing source blocks
* org-src.el (org-src-window-setup, org-src-switch-to-buffer): Added
  new split-window-right option which splits horizontally.

This has been motivated by the increasing use of wide monitors.
2019-08-17 15:26:32 +02:00
Henrik Koschitzki 4e854974be ob-plantuml: Allow different @start-/@end clauses
* lisp/ob-plantuml (org-babel-plantuml-make-body) Do not insert
@startuml and @enduml if body already starts with "@start".

PlantUML supports non-UML diagrams that have to be enclosed with
@startgantt/@endgantt for example.  The code for these diagrams can
contain the proper clauses without being enclosed additionally with
@startuml/@enduml.
2019-08-17 14:26:26 +02:00
Renato Ferreira 413736f315 org-todo: Respect state argument when called from elisp
* lisp/org.el (org-todo): Respect argument when called from elisp when
calling from elisp (such as in `org-clock-in').

Fast selection should only be shown if a state argument was not used.
This fixes a regression introduced by f1c030bed (Prefix argument to
`org-todo' forces stage change logging, 2019-08-14).

TINYCHANGE
2019-08-16 18:30:09 -04:00
Marco Wahl f51e88bed8 Fix descriptive text in the menu of org-search-view 2019-08-16 13:17:28 +02:00
Carsten Dominik 59ae60c26a Add `org-overriding-columns-format' as an option in custom views
* lisp/org-agenda.el (org-agenda-custom-commands-local-options): Add
`org-overriding-columns-format'.
2019-08-16 09:49:29 +02:00
Carsten Dominik 07e48a7af6 Merge branch 'fix-org-columns-formatdocumentation' 2019-08-16 09:37:54 +02:00
Carsten Dominik 6dda536f9f Clear up unclear setting of columns format for the agenda
* lisp/org.el (org-columns-default-format-for-agenda): New option.

* lisp/org-colview.el (org-overriding-columns-format): Updated documentation.
(org-agenda-columns): `Use org-columns-default-format-for-agenda'

* doc/org-manual.org (Using Column View in the Agenda): Fix the
description how to set the columns format for agenda views.
2019-08-16 09:34:55 +02:00
Carsten Dominik 92c2265794 Merge branch 'improve-fast-todo-selection' 2019-08-16 08:49:43 +02:00
Nicolas Goaziou 299ec9e721 Merge branch 'maint' 2019-08-15 10:06:21 +02:00
Nicolas Goaziou bf8ae63588 ox-latex: Fix typo in Brazilian language code
* lisp/ox-latex.el (org-latex-babel-language-alist): Fix typo.
2019-08-15 10:05:42 +02:00
Carsten Dominik 4d88d41430 Cleanup code 2019-08-14 10:32:03 +02:00
Carsten Dominik f1c030bed5 Prefix argument to `org-todo' forces stage change logging
* lisp/org.el (org-use-fast-todo-selection): Allow values
`auto' and `expert'.
(org-todo): Change the interpretation of the prefix argument.
A single `C-u' now forces taking a logging time stamp and note.
(org-fast-todo-selection): Implement the `expert' option of
`org-use-fast-todo-selection' and avoid showing the selection
window.  Instead, show the options in the prompt.

* doc/org-manual.org: (Basic TODO Functionality): Document that `C-u
C-c C-t' is the simplest way to log a TODO state change.
(TODO keywords as workflow states): Slightly simplify text.
(TODO keywords as types): Document that tags should be used instead.
(Progress Logging, Closing items, Tracking TODO state changes):
Document that `C-u C-c C-t' is the simplest way to log a TODO
state change.
(Remote editing): Document using a prefix to the `org-agenda-todo'
command logs the state change.
(Using CDLaTeX to enter math): Document that CDLaTeX is	available on
MELPA.

* doc/org-guide.org (Progress Logging): Document the use of a
prefix to `org-todo' to force logging.
2019-08-14 09:58:38 +02:00
Carsten Dominik f5d27e046a Fix bug dealing with the width field of categories in agenda
lisp/org-agenda.el (org-compile-prefix-format): Fix bug dealing with
the width field of categories.  Fix by Héctor Enríquez Ramón.
2019-08-12 13:30:38 +02:00
Carsten Dominik e3856a0c8e Fix tag alignment after todo state change with empty headline
* lisp/org.el (org-todo): Fix tag alignment with empty headline.
2019-08-12 11:35:29 +02:00
Carsten Dominik 495826e897 Make it customizable if block lines should be fontified to end
* lisp/org.el (org-fontify-whole-block-delimiter-line): New option.

* lisp/org.el (org-fontify-meta-lines-and-blocks-1): Use
`org-fontify-whole-block-delimiter-line'. Also, clean-up the function.
2019-08-12 09:03:29 +02:00
Carsten Dominik 20d9fefe4e Hide drawer contenxt after sorting entries
2019-08-10  Carsten Dominik  <carsten.dominik@gmail.com>

* lisp/org.el (org-sort-entries): Hide drawers after sort.
2019-08-10 07:58:28 +02:00
Carsten Dominik de3faf0767 Improve TODO selection if some keys are present in several sequences
* lisp/org.el (org-todo): Give the current state as an
argument to `org-fast-todo-selection'.
(org-fast-todo-selection): Accept current state as an
argument.  Use that state to find out to which TODO sequence
the current state belongs and use that to make the right
choice if selection keys are not unique globally.  For
example, if you have a task sequence, and a project sequence,
you could use the "d" selection key in both sequences to
switch to the appropriate DONE (or e.g. PRDN) state.
2019-08-09 23:00:21 +02:00
Carsten Dominik db6952cfe4 Improve docstring of `org-todo' 2019-08-09 10:04:02 +02:00
Gustav Wikström 60e5faf676 org-element: Fixing typo's 2019-08-03 13:35:27 +02:00
Gustav Wikström b082de626d org-id: Additional id method; ISO8601 timestamp
* New choice in org-id-method

Timestamps can be chosen as org-id-method.  This id-method has the
benefit of being human-readable and has synergies with org-attach if
one likes to organize attachment directories by timestamp instead of
by random names.
2019-08-02 17:02:01 +02:00
Gustav Wikström 9104c0c52d org-id: New customization, org-id-locations-file-relative
* org-id-locations-file-relative

New customization that allows the user to specify that filenames
should be saved relative to the file specified in
org-id-locations-file, instead of being absolute paths.

* org-id-locations-save

Respects new custom variable, org-id-locations-file-relative, and
can save locations with relative filenames.

* org-id-locations-load

Updated to be able to deal with relative filenames if they exist.
2019-08-02 17:00:01 +02:00
Gustav Wikström 9865e6bd8b org-id: Speedup, minor functional change and fix
* org-id-update-id-locations

Major speedup and minor functionality change.  This function is more
predictable now since local open files are not considered.  Providing
files as arguments to the function does no longer override other
files.  They are instead seen as a complement.

* org-id-add-location

Don't add duplicates.

* org-id-hash-to-alist

Fixed function, previously didn't do its job correctly.
2019-08-02 15:35:19 +02:00
Nicolas Goaziou ff6508ad4b Bump Version keyword
* lisp/org.el: Bump Version keyword.

This is necessary for GNU ELPA. Ideally, such a change should be
tagged with the official release.
2019-08-02 09:55:53 +02:00
Carsten Dominik 4910bec3aa Bug fix for previous commit 2019-08-01 08:35:47 +02:00
Carsten Dominik 64739aa065 Implement force logging of a TODO state change
* lisp/org.el (org-todo): Make a tripple `C-u' prefix force
          logging the todo state change with timestamp and a note.
          Ignoting blocking a change now needs four `C-u' prefixes,
          because this is probably hardly ever used.

	* doc/org-manual.org (Tracking TODO state changes): Document
          forcing of state change logging with `C-u C-u C-u C-c C-t'.
2019-08-01 08:10:20 +02:00
Carsten Dominik 2d08e9d4be Merge branch 'master' of code.orgmode.org:bzg/org-mode 2019-07-27 22:04:06 +02:00
Carsten Dominik e413e7695c Keep brackets around capture link annotation, to protect spaces
2019-07-27  Carsten Dominik  <carsten.dominik@gmail.com>

	* lisp/org-capture.el (org-capture-fill-template): Keep [[]]
	around the %l link annotation.

When capture is called from a buffer and the template includes a %l
annotation, then this link needs to be enclosed in [[ ... ]].  The
default link is a search link that searches for the line at point -
and when the link contains whitespace, it needs to be part of the link.
2019-07-27 21:57:21 +02:00
Kyle Meyer 29f96ef1b7 Merge branch 'maint' 2019-07-23 23:25:05 -04:00
Kyle Meyer be47489c31 org-gnus: Add note about integer overflow guard
* lisp/org-gnus.el (org-gnus-follow-link): Add compatibility note to
code that guards against integer overflow.

Emacs's 7e294d55e1 (Remove some obsolete integer overflow handling,
2019-07-22) removes this, but we can't port that for compatibility
reasons.
2019-07-23 23:24:13 -04:00
Marco Wahl 09a15f4d7f org-agenda: Unify user interfaces for bulk action and tag filtering 2019-07-24 00:37:01 +02:00
Marco Wahl 669cbe4653 Merge remote-tracking branch 'origin/master' 2019-07-15 00:31:35 +02:00
Marco Wahl dc2198971b org-agenda: Respect narrowing for agenda restricted to buffer
* lisp/org-agenda.el (org-agenda): Add a condition to check if
  narrowing is in effect and in case set the agenda restriction markers.
* etc/ORG-NEWS (Respect narrowing when agenda command is restricted to buffer):
* doc/org-manual.org (The Agenda Dispatcher): Mention the behavior.
2019-07-15 00:22:51 +02:00
Nicolas Goaziou 6786fb2e31 Merge branch 'maint' 2019-07-15 00:00:25 +02:00
Marcin Borkowski 3b006f9a3e Fix a bug when `org-agenda-todo-ignore-deadlines` is set to t
* lisp/org-agenda.el (org-agenda-check-for-timestamp-as-reason-to-ignore-todo-item):
Make `t' synonymous with `near' instead of `all' (as is stated in the
docstring).
2019-07-14 23:59:55 +02:00
Kyle Meyer 57e254e67c Merge branch 'maint' 2019-07-14 11:14:54 -04:00
Ismail S 64262af685 Backport commit fb48eb48f from Emacs
* lisp/org-capture.el (org-capture-templates): Fix typo in doc
string (bug#36491).

Fix minor typo in org-capture-templates
fb48eb48f3bd432307821bc7158d1090f0e4bbf0
Ismail S
Tue Jul 9 00:53:18 2019 +0200

TINYCHANGE
2019-07-14 11:12:33 -04:00
Konstantin Kharlamov c0d699e9ba Backport commit dfc322d77 from Emacs
* lisp/org-mobile.el (org-mobile-copy-agenda-files)
(org-mobile-update-checksum-for-capture-file):
* lisp/org-table.el (org-table-number-regexp):
Replace various combinations of [0-9a-fA-F] with [[:xdigit:]].
(Bug#36167)

Replace manually crafted hex regexes with [:xdigit:]
dfc322d77fd1ce3aa4d852e0ff07bb36944f6432
Konstantin Kharlamov
Sat Jul 6 10:54:25 2019 +0300
2019-07-14 11:12:12 -04:00
Marco Wahl 63b9c2634e Merge branch 'master' into compact-folding-refinement 2019-07-13 23:21:12 +02:00
Marco Wahl d2a5a6e4d0 Make feature "show children" applicable to whole file
* lisp/org.el (org-ctrl-c-tab): Make function applicable to a whole
  file.  Further flag (aka hide) all content in the subtrees.
2019-07-13 22:30:02 +02:00
Marco Wahl fd63eee797 Make feature "show branches" applicable to whole file
* lisp/org.el (org-kill-note-or-show-branches): Extend and refactor.
2019-07-13 22:29:29 +02:00
Nicolas Goaziou 2c8e8b4a18 contrib: Remove Org Drill
* contrib/README:
* lisp/org.el (org-modules): Remove reference to Org Drill.
contrib/lisp/org-drill.el: Remove file.

Org Drill is now developed externally, and available through an
ELPA (MELPA at this point).
2019-07-11 22:55:02 +02:00
Marco Wahl ee4fcc2aaa Add function to show just every headline in buffer
* lisp/org.el (org-show-branches-buffer): New function.
2019-07-11 12:12:37 +02:00
Marco Wahl add2614cf9 Add function to flag region above first heading
* lisp/org.el (org-flag-above-first-heading): New function.
2019-07-11 12:08:47 +02:00
Nicolas Goaziou 1ff9cab0a3 Merge branch 'maint' 2019-07-09 12:43:29 +02:00
Nicolas Goaziou 9bde6350d1 ox: Add post-blanks when latex is verbatim
* lisp/ox.el (org-export--remove-uninterpreted-data): Add post-blanks
  when latex is verbatim.
2019-07-09 12:42:46 +02:00
Nicolas Goaziou fae13929f4 Merge branch 'maint' 2019-07-09 11:57:21 +02:00
Nicolas Goaziou d73f65b57a org-list: Fix wrong list indentation
* lisp/org-list.el (org-list-struct-indent): Small refactoring.
(org-list-indent-item-generic): Copy old structure so
`org-list-write-struct' can notice bullet change.

Reported-by: Gustavo Barros <gusbrs.2016@gmail.com>
<http://lists.gnu.org/r/emacs-orgmode/2019-07/msg00033.html>
2019-07-09 11:56:47 +02:00
Gustav Wikström ae9cd4370b org-attach*, org, org-manual, org-news, ox-html, testing/*
* lisp/org-attach.el

Changed the way attachments deal with property-inheritance.  It now
adheres to the =org-use-property-inheritance= setting by default but
it can be customized if needed (I recommend to enable it!).
The property ATTACH_DIR is deprecated in favour of the shorter and simpler
property DIR.

Added an explicit option to =org-attach= for unsetting
attachment-directories (i.e. remove DIR property and deal with the
attachments by interaction).

Added attachment link type with the prefix "attachment:".

Added customizations:
- org-attach-dir-relative
- org-attach-preferred-new-method
- org-attach-use-inheritance
- org-attach-id-to-path-function

Hooks added:
- org-attach-after-change-hook
- org-attach-open-hook

A new linktype "attachment" is added in order to reduce
link-duplication when wanting to link to files in attached folders of
nodes.  This works for both ID and DIR properties.  The goal is to
make the functionality for attachment links mirror the functionality
for file links.

* lisp/org-attach-git.el

New file, existing functionality.  Code here has been factored out
from org-attach.el and if GIT-functionality is to be used this module
needs to be required sepatately.  It extends org-attach by use of its
hooks.

Activating git functionality in org-attach is done by loading
org-attach-git from now on, instead of customizing a variable.

Naming of both functions and tests has been modified to match the move
of functionality into its own module.

* lisp/org.el

Inline images are shown also using attachment-links, exactly the same
as it works for file-links today.

Make org-open-at-point respect ARG when opening attachment-dir.

* lisp/org-compat.el

org-attach-directory has been deprecated in favour for
org-attach-id-dir.  The new name matches its purpose better.

* lisp/ox-html.el

Export attachment links to images as inline images, in the same way as
file links work today.

* etc/ORG-NEWS

Mention the changes in this patch.

* doc/org-manual.org

The chapter "Refile, Copy, Archive" has been split into two separate
chapters.
- "Refile, Copy and Archiving" for information related to moving
  existing data around.

- "Capture, Attachments, RSS Feeds and Protocols" for information
  related to working with external data.

The attachment-part has been rewritten and extended to match the
changes in this patch.

The new attachment link type is mentioned both inside the attachments
chapter and in the chapter dealing with links.

Documentation related to external links has been improved.

* testing/lisp/test-org-attach-annex.el

Require org-attach-git instead of org-attach, since this file tests
the GIT-functionality.

* testing/lisp/test-org-attach.el

Add tests for org-attach.

* testing/org-test.el

Define a symbol for a file to test attachments with.

* testing/examples/*

A bunch of new example files and folders are created and are used in
testing of org-attach to verify its functionality.
2019-07-07 19:55:49 +02:00
Nicolas Goaziou 0201d1c0cc Fix inserting capture templates at point
* lisp/org-capture.el (org-capture):
(org-capture-set-target-location):
(org-capture-place-entry):
(org-capture-place-item):
(org-capture-place-table-line): Fix inserting capture templates at
point.  Insert a new internal property for capture
template: :insert-here.
(org-capture-insert-template-here): Remove function.

* testing/lisp/test-org-capture.el (test-org-caputre/entry):
(test-org-capture/item):
(test-org-capture/table-line): Add tests.

Reported-by: Dominic Surano <sk8ingdom@gmail.com>
<http://lists.gnu.org/r/emacs-orgmode/2019-07/msg00002.html>
2019-07-06 16:02:37 +02:00
Nicolas Goaziou 1b3c7c28cf Merge branch 'maint' 2019-07-06 10:25:18 +02:00
Nicolas Goaziou acf4f0881a org-agenda: Fix "Args out of range" error in `org-agenda-list'
* lisp/org-agenda.el (org-agenda-list): Do not add text properties on
empty headers.
2019-07-06 10:24:11 +02:00
Nicolas Goaziou b855acc878 Merge branch 'maint' 2019-06-28 17:50:53 +02:00
Nicolas Goaziou 7bc6f8d619 org-table: Prevent formula evaluation from widening all tables
* lisp/org-table.el (org-table-recalculate): When a formula is
  evaluated, do not expand shrunk columns across the whole buffer.
2019-06-28 17:49:25 +02:00
Nicolas Goaziou 9ddfe45314 org-table: Improve `org-table-copy-down'
* lisp/org-table.el (org-table--increment-field): New function.
(org-table-copy-down): Use new function.
* testing/lisp/test-org-table.el (test-org-table/copy-down): New test.
* doc/org-manual.org (Calculations): Update documentation.
2019-06-28 00:07:25 +02:00
Nicolas Goaziou 7e4847a554 Merge branch 'maint' 2019-06-28 00:06:58 +02:00
Nicolas Goaziou 0553f2e31c org-table: Fix `org-table-next-row' at eob
* lisp/org-table.el (org-table-next-row): Fix misbehaviour when called
  on the last row, at the end of the buffer, without a final newline.
2019-06-28 00:05:44 +02:00
Kyle Meyer 8e7280896f org-attach: Bind org-attach-method for org-attach-url
* lisp/org-attach.el (org-attach-url): Let-bind org-attach-method to
`url` so that org-attach-attach calls the correct method.

Before 72124726a (org-attach: Make dispatcher commands customizable,
2019-04-26), the dispatcher masked this issue by let-binding
org-attach-method around its call to org-attach-url.

Reported-by: stardiviner <numbchild@gmail.com>
<https://lists.gnu.org/archive/html/emacs-orgmode/2019-06/msg00130.html>
2019-06-21 18:15:52 -04:00
Aaron L. Zeng 1b74ae0ba3 org-clock: Clear org-clock-current-task on clock cancel
* org-mode/lisp/org-clock.el (org-clock-cancel): Clear
`org-clock-current-task' when a clock is canceled.

This variable is used by some mode line packages (e.g.,
spaceline-all-the-icons), so not clearing the variable incorrectly
displays the previous task as ongoing.
2019-06-15 11:53:42 +02:00
Nicolas Goaziou 439782ae00 Merge branch 'maint' 2019-06-12 18:22:50 +02:00
Thomas Plass 0d7d12ffe6 ox: Make `org-export-table-cell-alignment' more robust
* lisp/ox.el (org-export-table-cell-alignment): Make
`org-export-table-cell-alignment' handle tables with rows containing
unequal numbers of cells.

Patch modeled after previous fix for `org-export-table-cell-width'.

TINYCHANGE
2019-06-12 18:22:00 +02:00
Neil Jerram 85711ba3d9 Make capture's idea of the current day more intuitive 2019-06-10 11:20:20 +02:00
Nicolas Goaziou c30fe929cd Merge branch 'master' of code.orgmode.org:bzg/org-mode 2019-06-10 11:17:31 +02:00
Nicolas Goaziou 3ecf1fb7b9 ox: Silence byte-compiler
* lisp/ox.el (org-export-resolve-link): Use `org-link-make-string'
  instead of `org-make-link-string'.
2019-06-10 09:43:37 +02:00
Kyle Meyer 81920b3f86 Merge branch 'maint' 2019-06-09 21:39:18 -04:00
Paul Eggert 55e19d973e Backport commit 797ee5871 from Emacs
The convention is that a file with Author: but not Maintainer:
means the author is a maintainer, which makes it confusing
when a file lists the same person as author and maintainer.
Avoid the confusion by removing the duplicate Maintainer: line.

Remove Maintainer: when it duplicates Author:
797ee5871e458d6d97f57a24405412a053f5ef32
Paul Eggert
Sun May 26 01:00:15 2019 -0700
2019-06-09 21:28:44 -04:00
Paul Eggert 43bdc85b9d Backport commit 542443645 from Emacs
* lisp/org-id.el (org-id-link-to-org-use-id):
* lisp/org.el (org-support-shift-select, org-file-apps):
Remove backslash-newline that immediately precedes another
newline, as this is not the usual style and is confusing.

Avoid backslash-newline-newline in source code
5424436452bc0b3d8a62a8398f92d0c2db81e22b
Paul Eggert
Wed May 22 23:59:36 2019 -0700
2019-06-09 21:26:08 -04:00
Paul Eggert 96f439226e Backport commit bef1be873 from Emacs
Fixes for "Maintainer:" and related lines
bef1be873009d6e9f5a097396179f63a565bb6fd
Paul Eggert
Sun May 19 21:34:27 2019 -0700
2019-06-09 21:25:24 -04:00
Nicolas Goaziou 0ff65e9f4c org-list: Change `org-list-to-subtree' signature
* lisp/org-list.el (org-list-to-subtree): Add optional argument to
  specify level of the subtree.
(org-list-make-subtree):
* lisp/org.el (org-toggle-heading): Adapt to signature change.

Reported-by: Felix Wiemuth <felixwiemuth@hotmail.de>
<http://lists.gnu.org/r/emacs-orgmode/2019-06/msg00010.html>
2019-06-10 00:19:32 +02:00
Nicolas Goaziou bba9116cb8 org-element: Parse affiliated keywords according to granularity
* lisp/org-element.el (org-element--current-element): Parse affiliated
  keywords according to granularity.
* lisp/ox.el (org-export-get-caption): Refactor code.
* testing/lisp/test-org-element.el (test-org-element/affiliated-keywords-parser):
  Add tests.

Reported-by: ihor <ihor@antonovs.family>
<http://lists.gnu.org/r/emacs-orgmode/2019-06/msg00023.html>
2019-06-09 00:51:53 +02:00
Nik Clayton 380e2f7f82 ox-html: Include the line number as a data attribute
* lisp/ox-html.el (org-html-do-format-code): If line numbers are enabled
then include a data-ox-html-linenr attribute that contains this line's
line number.

This allows you to have more control over line number formatting and
placement. For example, the following CSS hides the span that contains
the line number, and uses a CSS :before property to position and format
the line number with a border instead of a semi-colon separating content
and line number.

span.linenr { display: none; }

code[data-ox-html-linenr]:before {
  content: attr(data-ox-html-linenr);
  display: inline-block;
  border-right: 1px solid;
  width: 1rem;
  text-align: right;
}

TINYCHANGE
2019-06-07 23:32:11 +02:00
Nik Clayton ded3d27b14 ox-html: Wrap each line of a source block in a code element
* lisp/ox-html.el (org-html-do-format-code): Wrap each line of a source block
in a code element.

This makes it straightforward to add custom decorations to each line
using CSS :before and :after properties.

TINYCHANGE
2019-06-07 23:32:08 +02:00
Nicolas Goaziou ba943ac855 ox-md: Silence byte compiler 2019-06-05 18:34:38 +02:00
Nicolas Goaziou 5832c8fc93 Fix `org-image-actual-width' behaviour
* lisp/org.el (org-image-actual-width): Improve docstring.
(org-display-inline-images): Ignore case when looking for ATTR
keywords.  Refactor code.

Reported-by: 'Ihor Radchenko' <yantar92@gmail.com>
<http://lists.gnu.org/r/emacs-orgmode/2019-06/msg00030.html>
2019-06-05 18:31:35 +02:00
Sacha Chua a41e9950ae Add :target option for the TOC keyword
* doc/org-manual.org, etc/ORG_NEWS: Document :target option
  for the TOC keyword.

* lisp/ox.el (org-export-resolve-link): New function.

* lisp/ox-ascii.el (org-ascii-keyword): Added :target to the TOC
  keyword.
  (org-ascii--build-toc): Changed LOCAL argument to SCOPE.

* lisp/ox-html.el (org-html-keyword): Added :target to the TOC keyword.

* lisp/ox-md.el (org-md-keyword): Added :target to the TOC keyword.
  (org-md--build-toc): Changed LOCAL argument to SCOPE.

* lisp/ox-odt.el (org-odt-keyword): Added :target to the TOC keyword.

* testing/lisp/test-ox.el (test-org-export/collect-headlines): Added
  tests for specifying scope by CUSTOM_ID or by fuzzy matching.
  (test-org-export/resolve-link): New test.
2019-05-30 15:25:46 +02:00
Nicolas Goaziou 99aa99426d Merge branch 'maint' 2019-05-30 14:59:58 +02:00
Nicolas Goaziou 967801e2b8 ox: Make `org-export-table-cell-width' more robust
* lisp/ox.el (org-export-table-cell-width): Make
  `org-export-table-cell-width' robust against malformed tables.

Reported-by: michael <m.schoenwaelder@posteo.de>
<http://lists.gnu.org/r/emacs-orgmode/2019-05/msg00215.html>
2019-05-30 14:59:10 +02:00
Nicolas Goaziou b373e688be Merge branch 'maint' 2019-05-30 14:19:49 +02:00
Nicolas Goaziou 24555a0c00 Revert "Fix strike-through fontification on heading"
This reverts commit 42abf5c695.
2019-05-30 14:19:09 +02:00
Andrii Kolomoiets c103bc5acf org-clock: Fix restore of `frame-title-format`
* lisp/org-clock.el (org-frame-title-format-backup): Use nil as initial value.
(org-clock-in): set `org-frame-title-format-backup' to `frame-title-format'.
(org-clock-restore-frame-title-format): New function.
(org-clock-out): Use it.
(org-clock-cancel): Use it.

The problem was that the `org-frame-title-format-backup' variable is
initialized on org-clock.el loading and future changes to `frame-title-format'
is ignored.

TINYCHANGE
2019-05-28 19:58:52 +02:00
Nicolas Goaziou 4a383ee0f1 Merge branch 'maint' 2019-05-28 11:20:21 +02:00
Cheong Yiu Fung e4f5a194c7 org.el: Fix docstring of org-latex-packages-alist
* lisp/org.el (org-latex-packages-alist): Fix docstring to match
`org-latex-default-packages-alist'

TINYCHANGE
2019-05-28 11:19:51 +02:00
Nicolas Goaziou ff2bf22655 ox-html: Small refactoring
* lisp/ox-html.el (org-html--build-pre/postamble): Prefer `and' over
  `when' for short Sexps where return value matters.
2019-05-21 10:24:11 +02:00
Nicolas Goaziou f45caca608 Merge branch 'maint' 2019-05-21 10:17:37 +02:00
Nicolas Goaziou 31873ed27d ox-html: Do not generate empty validation link
* lisp/ox-html.el (org-html--build-pre/postamble): Do not generate
  empty validation link.

Reported-by: Nick Dokos <ndokos@gmail.com>
<http://lists.gnu.org/r/emacs-orgmode/2019-05/msg00153.html>
2019-05-21 10:16:51 +02:00
Nicolas Goaziou 2579d88323 ox-latex: Allow labels in matrices
* lisp/ox-latex.el (org-latex--label): Add "eq:" prefix for matrices.
(org-latex-link): Properly refer to matrices.
(org-latex--wrap-latex-matrices): Inherit name from first table.
(org-latex-matrices): Insert label within "equation" environment.

Reported-by: edgar@openmail.cc
<http://lists.gnu.org/r/emacs-orgmode/2019-05/msg00095.html>
2019-05-13 00:51:39 +02:00
Nicolas Goaziou 50986c4863 ox: Resolve fuzzy links pointing to pseudo-elements
* lisp/ox.el (org-export-resolve-fuzzy-link): Look for name also in
  pseudo-elements.
2019-05-13 00:50:54 +02:00
Nicolas Goaziou 12f93c112b Use `org-flag-subtree' instead of `outline-hide-subtree'
* lisp/org-agenda.el (org-agenda-show-1):
* lisp/org-archive.el (org-archive-to-archive-sibling):
* lisp/org-crypt.el (org-encrypt-entry):
* lisp/org-feed.el (org-feed-update):
* lisp/org.el (org-set-visibility-according-to-property):
(org-move-subtree-down):
(org-paste-subtree):
(org-yank-generic):
* testing/lisp/test-org-inlinetask.el (test-org-inlinetask/folding-directly-consecutive-tasks/1): Use `org-flag-subtree' instead of `outline-hide-subtree'.

`outline-hide-subtree' leaves overlays on top of white spaces,
particularly at the end of the buffer. `org-flag-subtree' does not.
2019-05-11 09:48:53 +02:00
Nicolas Goaziou d79e80fc4a Merge branch 'maint' 2019-05-09 22:01:13 +02:00
Ingo Lohmar d1ce59571f Fix fast tag selection affecting wrong line
* lisp/org.el (org-fast-tag-selection): Wrap `save-window-excursion'
with `save-excursion'.

In the case when the tags are changed remotely from the agenda, and
the affected buffer is already visible in another window, the tag
change was applied to the currently visible line in the target buffer,
not the headline in the agenda.
2019-05-09 22:00:00 +02:00
Nicolas Goaziou f8d8da6491 Merge branch 'maint' 2019-05-07 09:36:41 +02:00
Nicolas Goaziou e91bf47e4d Fix docstring
* lisp/org.el (org-timestamp-change): Fix docstring.

Reported-by: Tim Landscheidt <tim@tim-landscheidt.de>
<http://lists.gnu.org/r/emacs-orgmode/2019-05/msg00047.html>
2019-05-07 07:32:20 +02:00
Nicolas Goaziou 9bbae3ce8f Merge branch 'maint' 2019-04-29 20:49:09 +02:00
Nicolas Goaziou 727c3f442b org-macro: Exit early when looking for keywords
* lisp/org-macro.el (org-macro--find-keyword-value): Change signature.
* testing/lisp/test-org-macro.el (test-org-macro/keyword): Remove
  a test.
2019-04-29 20:48:00 +02:00
Nicolas Goaziou 14132a356a Collect buffer-specific built-in macros in setup files
* lisp/org-macro.el (org-macro--set-template): New function.
(org-macro--collect-macros): Also collect "author", "email", "title"
and "date" macros.
(org-macro-initialize-templates): Do not collect previous macros here,
when it is too late.
(org-macro--find-date): New function.
* testing/lisp/test-org-macro.el (test-org/macro-replace-all): Remove
  test, since we cannot guarantee anymore that user-defined macros can
  take precedence over built-in ones.

Reported-by: emsenn <emsenn@emsenn.net>
<http://lists.gnu.org/r/emacs-orgmode/2019-04/msg00234.html>
2019-04-29 20:35:23 +02:00
Nicolas Goaziou 7cfc9ce95f Merge branch 'maint' 2019-04-27 18:54:51 +02:00
Kévin Le Gouguec 42abf5c695 Fix strike-through fontification on heading
* lisp/org.el (org-do-emphasis-faces): Fix face priority.
2019-04-27 18:52:57 +02:00
Eric Danan 72124726aa org-attach: Make dispatcher commands customizable
* lisp/org-attach.el (org-attach-commands): New custom variable.
(org-attach): Use the above variable.
2019-04-27 18:48:56 +02:00
Joaquín Aguirrezabalaga 4939b41750 ob-core: Fix :dir when :mkdirp is not defined
* lisp/ob-core.el (org-babel-execute-src-block): Fix behaviour of
  ":dir path" when ":mkdirp" is not defined.
* testing/lisp/test-ob.el (test-ob-core/dir-mkdirp): Add a test case.

TINYCHANGE
2019-04-25 10:36:40 +02:00
Nicolas Goaziou 0f9b7114d1 org-table: Fix `org-table-map-tables'
* lisp/org-table.el (org-table-map-tables): Apply function at the
  beginning of the table, not at the first affiliated keyword, if any.

Reported-by: Kaushal Modi <kaushal.modi@gmail.com>
<http://lists.gnu.org/r/emacs-orgmode/2019-04/msg00167.html>
2019-04-23 10:35:31 +02:00
Emmanuel Charpentier 5b7b0fa8fb ox-latex: Support a :scale parameter
* lisp/ox-latex.el (org-latex-image-default-scale): Nev variable.
(org-latex--inline-image): Handle new :scale parameter.
* doc/org-manual.org (Images in LaTeX export): document the new :scale

Introduce a :scale #+ATTR_LATEX parameter, as well as a "" default
value for it.  When present, it overrides :width and :height
parameters (as it does for ODT export and in ox-pandoc exporters).

Implementation: uses \scalebox for tikz/pgf images, "scale=" parameter
of \includegraphics in other cases.
2019-04-22 14:01:59 +02:00
Kyle Meyer b0add090cd Update stale link-related library names
* contrib/lisp/org-bibtex-extras.el: Update for rename of org-bibtex
to ol-bibtex.
* lisp/ox-icalendar.el: Update for rename of org-bbdb to ol-bbdb.

Reported-by: Jonas Bernoulli <jonas@bernoul.li>
<https://lists.gnu.org/archive/html/emacs-orgmode/2019-04/msg00143.html>
2019-04-20 15:02:54 -04:00
Nicolas Goaziou 65399aea48 ob-sql: Silence byte-compiler 2019-04-16 21:53:15 +02:00
Stefano Rodighiero f9a898d881 ob-sql: Option to reference connections in `sql-connection-alist'
* lisp/ob-sql.el (org-babel-find-db-connection-param): New function.

Provide a new param called :dbconnection, that can be used to
reference connections defined in `sql-connection-alist', a custom
variable defined in sql.el.

TINYCHANGE
2019-04-15 18:11:02 +02:00
Kyle Meyer 4f05529ac5 Merge branch 'maint' 2019-04-14 22:11:27 -04:00
Paul Eggert 9bf1bdaf25 Backport commit 7ddd08bd3 from Emacs
* lisp/org-table.el (org-table-range-regexp):
Omit or rewrite useless repetitions that risk being very slow in
the backtracking regexp engine in Emacs.

Omit/rewrite useless regexp repetitions
7ddd08bd3ebc48998062a7d29274cf080256a48f
Paul Eggert
Fri Apr 12 19:43:41 2019 -0700
2019-04-14 22:08:07 -04:00
Nicolas Goaziou ab311b85ae Merge branch 'maint' 2019-04-13 09:43:32 +02:00
Nicolas Goaziou 222408d70a org-table: Prevent expanding columns upon applying formulas
* lisp/org-table.el (org-table-recalculate): Prevent expanding columns
  upon applying formulas.
* testing/lisp/test-org-table.el (test-org-table/shrunk-columns): Add
  test.

Reported-by: Nick Dokos <ndokos@gmail.com>
<http://lists.gnu.org/r/emacs-orgmode/2019-04/msg00079.html>
2019-04-13 09:40:27 +02:00
Nicolas Goaziou 96b507bea8 org-table: Fix harmless code typo
* lisp/org-table.el (org-table-recalculate): Fix harmless code typo.
2019-04-13 09:30:19 +02:00
Nicolas Goaziou 09a1a24b73 ol: Fix `org-previous-link' skipping links
* lisp/ol.el (org-next-link): Do not skip links when searching
  backwards.

Reported-by: stardiviner <numbchild@gmail.com>
<http://lists.gnu.org/r/emacs-orgmode/2019-04/msg00022.html>
2019-04-10 15:26:46 +02:00
Nicolas Goaziou 21fa859c4d Merge branch 'maint' 2019-04-09 09:24:46 +02:00
Nicolas Goaziou 6efe53cf0b org-capture: Do not break planning when capturing items
* lisp/org-capture.el (org-capture-place-item): When there is no list
  to augment, insert new list after planning info and properties
  drawers.
* testing/lisp/test-org-capture.el (test-org-capture/item): Add tests.

Reported-by: Allen Li <darkfeline@felesatra.moe>
<http://lists.gnu.org/r/emacs-orgmode/2019-04/msg00060.html>
2019-04-09 09:23:00 +02:00
Nicolas Goaziou c0218ea746 org-src: New `org-src-get-lang-mode' function
* lisp/org-src.el (org-src-get-lang-mode): New function.
(org-src--get-lang-mode): Rename to `org-src-get-lang-mode'.
(org-src-font-lock-fontify-block):
(org-edit-latex-environment):
(org-edit-export-block):
(org-edit-src-code):
(org-edit-inline-src-code): Use new function.
2019-04-07 09:16:36 +02:00
Nicolas Goaziou 3375f039dd ol: Fix `org-next-link' in an item tag
* lisp/ol.el (org-next-link): Fix `org-next-link' in an item tag.
* testing/lisp/test-ol.el (test-ol/next-link): Add test.
2019-04-04 15:52:41 +02:00
Kyle Meyer 92a59795f1 Merge branch 'maint' 2019-04-02 19:07:21 -04:00
Paul Eggert b0324a7405 Backport commit f9ff60e0d from Emacs
* lisp/org-eshell.el (org-eshell-open):
* lisp/org.el (org-deadline-time-hour-regexp)
(org-scheduled-time-hour-regexp):
Avoid attempts to chain ranges, as this can be confusing.
For example, instead of [0-9-_.], use [0-9_.-].

Improve regexp advice again, and unchain ranges
f9ff60e0d7288e30cdbd1e43225059f1374441f1
Paul Eggert
Tue Apr 2 15:01:34 2019 -0700
2019-04-02 19:04:56 -04:00
Nicolas Goaziou da517aaeb8 Merge branch 'maint' 2019-04-02 22:12:10 +02:00
Nicolas Goaziou b913b7404b org-capture: Fix capture on empty entries
* lisp/org-capture.el (org-capture-fill-template): Prevent raising an
  error when template is an empty entry.
* testing/lisp/test-org-capture.el (test-org-caputre/entry): Add test.

Reported-by: Roland Everaert <reveatwork@gmail.com>
<http://lists.gnu.org/r/emacs-orgmode/2019-04/msg00019.html>
2019-04-02 22:10:50 +02:00
Bastien 01182eb775 org.el: Bump version number 2019-04-02 08:30:19 +02:00
Kyle Meyer d9afed12f4 Merge branch 'maint' 2019-03-24 20:44:13 -04:00
Paul Eggert 355eb9e08e Backport commit e14c0d748 from Emacs
* lisp/org-datetree.el (org-datetree--find-create):
* lisp/org-pcomplete.el (org-thing-at-point):
Fix regular expression and similar syntax.

More minor regex cleanup
e14c0d748efe35afc653151ff18c4dd93dcc456e
Paul Eggert
Tue Mar 19 18:47:53 2019 -0700
2019-03-24 20:39:52 -04:00
Paul Eggert c856b34bd1 Backport commit bc2a93d5b from Emacs
* lisp/org.el (org-increase-number-at-point)
(org-fill-line-break-nobreak-p):
Fix regular expression typos.

Fix more regular expression typos
bc2a93d5b7c3d749b31927452e31b32bdb1b9108
Paul Eggert
Mon Mar 18 17:02:29 2019 -0700
2019-03-24 20:35:02 -04:00
Nicolas Goaziou 3a2ef56195 Fix last commit
* lisp/org.el (org-dynamic-block-define): Fix match.
2019-03-22 18:36:02 +01:00
Nicolas Goaziou 6c88d8e406 Fix multiple calls to `org-dynamic-block-alist'.
* lisp/org.el (org-dynamic-block-define): Update entry instead of
  piling up entries of the same type.
2019-03-22 18:32:51 +01:00
Nicolas Goaziou a39ee98873 Turn `org-dynamic-block-alist' into a defvar
* lisp/org.el (org-dynamic-block-alist): Make it a defvar.  Update docstring.
2019-03-22 18:32:40 +01:00