Commit Graph

18008 Commits

Author SHA1 Message Date
Nicolas Goaziou 9db78611b4 Tweak `org-auto-repeat-maybe'
* lisp/org.el (org-auto-repeat-maybe): Only clear non-repeated SCHEDULED
  information in a repeated task.

* doc/org.texi (Repeated tasks): Document behavior.

Do not clear non-repeated DEADLINE information however, as it could be
a global deadline for all occurrences of the task.  Also, this case is
taken care of by `org-agenda-skip-scheduled-if-deadline-is-shown' with
a value set to `repeated-after-deadline'.
2016-01-11 12:11:22 +01:00
Nicolas Goaziou 157f91c31c Fix `org-auto-repeat-maybe'
* lisp/org.el (org-auto-repeat-maybe): Do not remove SCHEDULED time
  stamp when encountering a time stamp without a repeater.  Also, ensure
  "REPEAT_TO_STATE" property can be inherited.  Small refactoring.

Reported-by: "Bradley M. Kuhn" <bkuhn@ebb.org>
<http://permalink.gmane.org/gmane.emacs.orgmode/104103>
2016-01-11 00:58:53 +01:00
Nicolas Goaziou e2e5fc2f58 Tiny fixes to docstrings
* lisp/org.el (org-execute-file-search-functions):
(org-after-todo-statistics-hook):
(org-sparse-tree): Fix docstrings.
2016-01-11 00:00:25 +01:00
Nicolas Goaziou ef01789804 org.el: Use `dolist' instead of `mapc' + `lambda'
* lisp/org.el (org-babel-do-load-languages):
(org-load-modules-maybe):
(org-mode-transpose-word-syntax-table):
(org-cycle-internal-local):
(org-remove-empty-overlays-at):
(org-reinstall-markers-in-region):
(orgstruct++-mode):
(orgstruct++-mode):
(org-offer-links-in-entry):
(org-refile-cache-clear):
(org-revert-all-org-buffers):
(org-ctrl-c-ctrl-c):
(org-in-block-p):
(org-uniquify-alist):
(org-unindent-buffer):
(org-imenu-get-tree): Use `dolist' instead of `mapc' + `lambda'.

(org-show-block-all):
(org-remove-occur-highlights):
(org-remove-inline-images):
(org-speed-command-help):
(org-require-autoloaded-modules): Use #'fun instead of 'fun for clarity.
2016-01-10 21:16:29 +01:00
Nicolas Goaziou 1f49e9fdfd org.el: Switch to lexical binding
* lisp/org.el (org-version):
(org-extract-log-state-settings):
(org-before-change-function):
(org-mode):
(org-emphasize):
(org-fontify-meta-lines-and-blocks-1):
(org-update-radio-target-regexp):
(org-unfontify-region):
(org-set-visibility-according-to-property):
(org-set-outline-overlay-data):
(org-goto-ret):
(org-insert-heading):
(org-contextualize-validate-key):
(org--links-history):
(org-insert-link):
(ido-enter-matching-directory):
(org-offer-links-in-entry):
(org-link-search):
(org-open-file):
(org-refile):
(org-add-log-note):
(org-occur-next-match):
(org-remove-occur-highlights):
(org-priority):
(org-tags-completion-function):
(org-map-entries):
(org-entry-properties):
(org-buffer-property-keys):
(org-property-values):
(org-property-previous-allowed-value):
(org-find-olp):
(calendar-setup):
(org-read-date):
(org-read-date-analyze):
(org-check-before-date):
(org-check-after-date):
(org-calendar-holiday):
(org-diary-sexp-entry):
(org-closest-date):
(org-date-to-gregorian):
(org-recenter-calendar):
(org-agenda-prepare-buffers):
(org-cdlatex-underscore-caret):
(org-cdlatex-math-modify):
(org-create-math-formula):
(org-display-inline-remove-overlay):
(org-shiftmetaup):
(org-shiftmetadown):
(org-metaleft):
(org-metaright):
(org-metaup):
(org-metadown):
(org-in-src-block-p):
(org-replace-escapes):
(org-indent-region):
(org-comment-dwim):
(org-drag-line-forward): Silence byte-compiler
2016-01-10 21:16:29 +01:00
Nicolas Goaziou a02a83793b Make `org-make-tags-matcher' lexical binding friendly
* lisp/org.el (org-make-tags-matcher): Return a function instead of
  a sexp.  Refactor code.
(org--matcher-tags-todo-only): New variable.  Replace `todo-only'
dynamic binding.
(org-scan-tags): Apply changes to `org-make-tags-matcher'.
(org-match-sparse-tree):
(org-map-entries): Use new variable.

* lisp/org-crypt.el (org-encrypt-entries):
(org-decrypt-entries): Use new variable.

* lisp/org-clock.el (org-clock-get-table-data): Apply changes to
  `org-make-tags-matcher'.

* lisp/org-agenda.el (org-tags-view): Use new variable.
2016-01-10 21:16:29 +01:00
Nicolas Goaziou fdbf441560 Obsolete `org-icompleting-read' and `org-completing-read-no-i'
* lisp/org.el (org-icompleting-read, org-completing-read-no-i): Obsolete
  aliases for `completing-read'
(org-iswitchb-completing-read): Remove function.
(org-sort-entries):
(org-refile-get-location):
(org-todo):
(org-deadline):
(org-occur-parameters):
(org-change-tag-in-region):
(org-fast-tag-selection):
(org-delete-property-globally):
(org-compute-property-at-point):
(org-buffer-list): Use genuine function.

* contrib/lisp/org-colview-xemacs.el (org-columns-edit-value):
(org-columns-new):
(org-insert-columns-dblock):
* contrib/lisp/org-index.el (org-index):
* contrib/lisp/ox-bibtex.el (org-bibtex-goto-citation):
* lisp/ob-core.el (org-babel-insert-header-arg):
(org-babel-goto-named-src-block):
(org-babel-goto-named-result):
(org-babel-demarcate-block):
* lisp/org-agenda.el (org-todo-list):
(org-agenda-filter-by-tag):
(org-agenda-bulk-action):
* lisp/org-attach.el (org-attach-delete-one):
(org-attach-open):
* lisp/org-bibtex.el (org-bibtex-fleshout):
(org-bibtex-create):
* lisp/org-capture.el (org-capture-fill-template):
* lisp/org-colview.el (org-columns-edit-value):
(org-columns-new):
(org-insert-columns-dblock):
* lisp/org-footnote.el (org-footnote-new):
* lisp/org-list.el (org-sort-list):
* lisp/ox-publish.el (org-publish):
* lisp/ox.el (org-export-dispatch): Use genuine function.
2016-01-10 21:16:29 +01:00
Kyle Meyer 5964b711f9 Update copyright years for master-only files 2016-01-10 12:07:40 -05:00
Kyle Meyer 6345de2d05 Merge branch 'maint' 2016-01-09 17:43:27 -05:00
Marco Wahl 88a2f285f0 contrib/org-eww: Use lexical binding + 𝜀
* contrib/lisp/org-eww.el: Copyright year update.  Simplified program
 logic.  Replaced `replace-regexp' (following the advice of
 `elint-file'.)
2016-01-09 23:14:47 +01:00
Kyle Meyer 6bc48c5f41 Update copyright years 2016-01-09 17:12:03 -05:00
Nicolas Goaziou e0d3944985 Fix escaping in capture, part 2
* lisp/org-capture.el (org-capture-fill-template):
* lisp/org-feed.el (org-feed-format-entry): Fix wrong argument in
  `replace-regexp-in-string'.
2016-01-09 17:04:26 +01:00
Bastien 0468ca8529 Merge branch 'maint' 2016-01-09 08:15:46 +01:00
Bastien 7821d0b2d3 Fix copyright headers. 2016-01-09 08:15:24 +01:00
Nicolas Goaziou 42cf4cce52 org-feed: Switch to lexical binding
* lisp/org-feed.el (org-feed-update):
(org-feed-write-status): Silence byte-compiler.
2016-01-08 23:40:24 +01:00
Nicolas Goaziou e2fbaeedc1 Fix handling escaped placeholders in templates
* lisp/org-capture.el (org-capture-fill-template):
* lisp/org-feed.el (org-feed-format-entry): Fix handling escaped
  placeholders in templates.  In particular, do not rely on match data
  when `org-capture-escaped-%' is used.

Reported-by: Michael Brand <michael.ch.brand@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/104081>
2016-01-08 23:36:22 +01:00
Nicolas Goaziou da10c6ace6 Fix copyright years 2016-01-07 23:39:50 +01:00
Nicolas Goaziou 528a2741a4 org-feed: Silence byte-compiler 2016-01-07 23:38:20 +01:00
Nicolas Goaziou 910418282a Resurrect `org-log-note-marker'
* lisp/org.el (org-log-note-buffer): Remove variable.
(org-log-note-marker): New variable.
(org-log-note-effective-time): Fix docstring.
(org-add-log-setup):
(org-add-log-note):
(org-store-log-note): Use new variable.

Unlike to previous variable, this one stores the location of the entry
where the note is going to be inserted, not necessarily the location of
the note, which is computed later.
2016-01-07 23:33:27 +01:00
Nicolas Goaziou f56caace8a Fix `org-log-beginning'
* lisp/org.el (org-log-beginning): Properly locate notes when no drawer
  is used.
(org-store-log-note): Function above already moves point to the correct
location.
2016-01-07 23:13:37 +01:00
Nicolas Goaziou 1124b2fc2a org-feed: Fix `org-feed-format-entry'
* lisp/org-feed.el (org-feed-format-entry): Fix function according to
  recent changes to Org Capture library.  Small refactoring.

Reported-by: Michael Brand <michael.ch.brand@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/103941>
2016-01-07 17:32:24 +01:00
Nicolas Goaziou aa52550e4b org-capture: Fix sexp handling
* lisp/org-capture.el (org-capture-expand-embedded-elisp): Do not mark
  invalid sexp.  Renamed from `org-capture--expand-embedded-elisp'.
(org-capture-fill-template): Escape " characters for placeholders
located within sexp.  Small refactoring.
(org-capture-inside-embedded-elisp-p): Rewrite function.
2016-01-07 17:30:54 +01:00
Stefan-W. Hahn a902c830e7 Name org-tree indirect buffer just with title
* lisp/org.el (org-tree-to-indirect-buffer): Remove tags from name.

Just use org-tree title for naming an indirect org-tree buffer.  If tags
are appended the name clutters mode-line.

TINYCHANGE

Signed-off-by: Stefan-W. Hahn <stefan.hahn@s-hahn.de>
2016-01-06 22:59:54 +01:00
tsdye d5595ac671 Change "keybinding" to "key binding"
* doc/org.texi (Conventions):
(Clocking commands):
(Using capture):
(Key bindings and useful functions): Change "keybinding" to "key binding".
2016-01-06 22:53:56 +01:00
Nicolas Goaziou f4ffbccf64 Remove left-over :export-block keywords
* contrib/lisp/ox-freemind.el (freemind):
* contrib/lisp/ox-gfm.el (gfm):
* contrib/lisp/ox-groff.el (groff): Remove :export-block keyword.

* doc/org.texi (Adding export back-ends): Remove documentation about the
  keyword.

Reported-by: Kaushal Modi <kaushal.modi@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/104057>
2016-01-06 22:50:22 +01:00
Nicolas Goaziou 74c46ad006 ORG-NEWS: Signal :export-block keyword removal 2016-01-06 19:11:40 +01:00
Nicolas Goaziou aab46486f7 Fix removal of shared drawers between clocks and notes
* lisp/org.el (org-log-note-marker): Remove variable.
(org-log-note-buffer): New variable.
(org-add-log-setup): Remove one argument.  Also use new variable.
(org-refile):
(org-todo):
(org-auto-repeat-maybe):
(org-deadline):
(org-schedule):
(org-add-note): Apply argument removal.
(org-store-log-note): Use new variable.  Compute the insertion's location
at the time the note is really inserted in the buffer.

* lisp/org-clock.el (org-clock-out): Apply argument removal.  Remove hack
  around shared drawers.

Reported-by: Olli P <kotkis@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/103958>
2016-01-06 15:50:50 +01:00
Nicolas Goaziou c6ec704dce org-clock: Fix missing clock history
* lisp/org-clock.el (org-clock-stored-history): New variable.
(org-clock-save):
(org-clock-load): Use new variable.

Reported-by: Matt Lundin <mdl@imapmail.org>
<http://permalink.gmane.org/gmane.emacs.orgmode/103972>
2016-01-06 15:07:47 +01:00
Nicolas Goaziou 5792667bde Merge branch 'maint' 2016-01-06 14:51:04 +01:00
Nicolas Goaziou 005f8b2fd1 Add missing argument
* lisp/org.el (org-set-property): Add missing argument.
2016-01-06 14:50:37 +01:00
Nicolas Goaziou 93c52908b6 Merge branch 'maint' 2016-01-06 14:46:36 +01:00
Nicolas Goaziou 22cf1bf7ed Throw an error when trying to set invalid properties
* lisp/org.el (org--valid-property-p): New function.
(org-entry-put):
(org-set-property): Use new function.

Suggested-by: Julien Cubizolles <j.cubizolles@free.fr>
<http://permalink.gmane.org/gmane.emacs.orgmode/104044>
2016-01-06 14:45:52 +01:00
Nicolas Goaziou 8e273a3d32 org-capture: Fix code typo
* lisp/org-capture.el (org-capture-fill-template): Fix `pcase'.
2016-01-05 23:59:05 +01:00
Nicolas Goaziou b5515ace2f org-capture: Fix %^T capture place-holders with end-time
Reported-by: Charles Millar <millarc@verizon.net>
<http://permalink.gmane.org/gmane.emacs.orgmode/103981>
2016-01-05 23:30:01 +01:00
Daniele Pizzolli 4a6d195dea Fix typo 2016-01-03 20:56:35 +01:00
Nicolas Goaziou aa3917ad47 Merge branch 'maint' 2016-01-03 20:49:18 +01:00
Nicolas Goaziou 3d4c467673 org-clock: Improve docstring
* lisp/org-clock.el (org-clock-display): Point to
  `org-clock-display-default-range'.

Reported-by: David Bremner <david@tethera.net>
<http://permalink.gmane.org/gmane.emacs.orgmode/103938>
2016-01-03 20:48:14 +01:00
Nicolas Goaziou 4b7b201c77 Merge branch 'maint' 2016-01-02 17:40:41 +01:00
Nicolas Goaziou a03175d6d9 ob-tangle: Silence byte-compiler 2016-01-02 17:40:22 +01:00
Nicolas Goaziou 5e63baf92e Merge branch 'maint' 2016-01-02 17:06:53 +01:00
Nicolas Goaziou 59f00529d4 Update copyright years 2016-01-02 17:06:30 +01:00
Nicolas Goaziou e2ac979d9e ob-tangle: Fix commented links
* lisp/ob-tangle.el (org-babel-spec-to-string):
(org-babel-tangle-collect-blocks): Fix numbering and relative path of
commented links.

* testing/lisp/test-ob-tangle.el (ob-tangle/comment-links-numbering):
  New test.

Reported-by: Tobias Müller <mllertobias@gmx.de>
<http://permalink.gmane.org/gmane.emacs.orgmode/103861>
2016-01-02 17:05:00 +01:00
Nicolas Goaziou 8bc5d40264 Fix `org-toggle-heading'
* lisp/org.el (org-toggle-heading): Ensure partial list conversion to
  headlines do not get broken by missing newline characters.
2016-01-02 14:25:58 +01:00
Nicolas Goaziou ad4d4227f0 Merge branch 'maint' 2016-01-02 14:13:41 +01:00
Nicolas Goaziou 57b3a0f02b org-indent: Update coyright years 2016-01-02 14:12:24 +01:00
Nicolas Goaziou 4313417515 Merge branch 'maint' 2016-01-02 14:11:48 +01:00
Nicolas Goaziou 6da1d9fc32 org-indent: Fix refresh when using `org-toggle-heading'
* lisp/org-indent.el (org-indent-notify-modified-headline):
(org-indent-refresh-maybe): Ignore narrowing.  Also ignore inlinetasks.

Reported-by: Ingo Lohmar <i.lohmar@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/103919>
2016-01-02 14:10:49 +01:00
Nicolas Goaziou 3694450320 Fix copyright years 2016-01-02 13:36:44 +01:00
Nicolas Goaziou ad83f31318 org-pcomplete: Fix keyword and block completion
* lisp/org-pcomplete.el (pcomplete/org-mode/file-option): Apply removal
  of `org-element-block-name-alist'.
2016-01-02 13:35:58 +01:00
Nicolas Goaziou 7dc6748452 Fix export blocks
* lisp/org-element.el (org-element-export-block-parser): Type is always
  stored in capitals.

* testing/lisp/test-ox.el (test-org-export/export-block): Add test.

Reported-by: Suvayu Ali <fatkasuvayu+linux@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/103921>
2016-01-02 11:53:24 +01:00