summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKyle Meyer <kyle@kyleam.com>2019-03-17 22:56:24 -0400
committerKyle Meyer <kyle@kyleam.com>2019-03-17 22:56:24 -0400
commitc2f3f1912e78bd9eb0f79f28d876e97ab52f924c (patch)
tree5b13bdb3e5c010de46617cb3d937ee32febafa45
parent7d158baebeae9dc729f42246215db0b7eda38d93 (diff)
parent574695895403790f8c445d057139117a3d3069fa (diff)
downloadorg-mode-c2f3f1912e78bd9eb0f79f28d876e97ab52f924c.tar.gz
Merge branch 'maint'
-rw-r--r--lisp/ob-abc.el4
-rw-r--r--lisp/ob-core.el2
-rw-r--r--lisp/ob-forth.el2
-rw-r--r--lisp/ol-mhe.el2
-rw-r--r--lisp/org-agenda.el15
-rw-r--r--lisp/org-clock.el22
-rw-r--r--lisp/org-element.el2
-rw-r--r--lisp/org-list.el4
-rw-r--r--lisp/org-mobile.el4
-rw-r--r--lisp/org-mouse.el2
-rw-r--r--lisp/org-plot.el2
-rw-r--r--lisp/org-protocol.el2
-rw-r--r--lisp/org-table.el11
-rw-r--r--lisp/org.el5
-rw-r--r--lisp/ox-ascii.el4
-rw-r--r--lisp/ox-latex.el2
-rw-r--r--lisp/ox.el2
17 files changed, 45 insertions, 42 deletions
diff --git a/lisp/ob-abc.el b/lisp/ob-abc.el
index cefbe71..43ee1d9 100644
--- a/lisp/ob-abc.el
+++ b/lisp/ob-abc.el
@@ -47,7 +47,7 @@
(value (cdr pair)))
(setq body
(replace-regexp-in-string
- (concat "\$" (regexp-quote name))
+ (concat "\\$" (regexp-quote name))
(if (stringp value) value (format "%S" value))
body))))
vars)
@@ -59,7 +59,7 @@
(message "executing Abc source code block")
(let* ((cmdline (cdr (assq :cmdline params)))
(out-file (let ((file (cdr (assq :file params))))
- (if file (replace-regexp-in-string "\.pdf$" ".ps" file)
+ (if file (replace-regexp-in-string "\\.pdf$" ".ps" file)
(error "abc code block requires :file header argument"))))
(in-file (org-babel-temp-file "abc-"))
(render (concat "abcm2ps" " " cmdline
diff --git a/lisp/ob-core.el b/lisp/ob-core.el
index fbeb46b..02efa1d 100644
--- a/lisp/ob-core.el
+++ b/lisp/ob-core.el
@@ -2954,7 +2954,7 @@ If the table is trivial, then return it as a scalar."
(defun org-babel-string-read (cell)
"Strip nested \"s from around strings."
(org-babel-read (or (and (stringp cell)
- (string-match "\\\"\\(.+\\)\\\"" cell)
+ (string-match "\"\\(.+\\)\"" cell)
(match-string 1 cell))
cell) t))
diff --git a/lisp/ob-forth.el b/lisp/ob-forth.el
index 8eac454..2d61de3 100644
--- a/lisp/ob-forth.el
+++ b/lisp/ob-forth.el
@@ -53,7 +53,7 @@ This function is called by `org-babel-execute-src-block'"
(defun org-babel-forth-session-execute (body params)
(require 'forth-mode)
(let ((proc (forth-proc))
- (rx " \\(\n:\\|compiled\n\\\|ok\n\\)")
+ (rx " \\(\n:\\|compiled\n\\|ok\n\\)")
(result-start))
(with-current-buffer (process-buffer (forth-proc))
(mapcar (lambda (line)
diff --git a/lisp/ol-mhe.el b/lisp/ol-mhe.el
index 02dc464..b2c163c 100644
--- a/lisp/ol-mhe.el
+++ b/lisp/ol-mhe.el
@@ -142,7 +142,7 @@ So if you use sequences, it will now work."
"Return the name of the message folder in an index folder buffer."
(save-excursion
(mh-index-previous-folder)
- (if (re-search-forward "^\\(+.*\\)$" nil t)
+ (if (re-search-forward "^\\(\\+.*\\)$" nil t)
(message "%s" (match-string 1)))))
(defun org-mhe-get-message-folder ()
diff --git a/lisp/org-agenda.el b/lisp/org-agenda.el
index 90b8802..f6f501b 100644
--- a/lisp/org-agenda.el
+++ b/lisp/org-agenda.el
@@ -2909,13 +2909,12 @@ Pressing `<' twice means to restrict to the current subtree or region
(let* ((m (org-agenda-get-any-marker))
(note (and m (org-entry-get m "THEFLAGGINGNOTE"))))
(when note
- (message (concat
- "FLAGGING-NOTE ([?] for more info): "
- (org-add-props
- (replace-regexp-in-string
- "\\\\n" "//"
- (copy-sequence note))
- nil 'face 'org-warning)))))))
+ (message "FLAGGING-NOTE ([?] for more info): %s"
+ (org-add-props
+ (replace-regexp-in-string
+ "\\\\n" "//"
+ (copy-sequence note))
+ nil 'face 'org-warning))))))
t t))
((equal org-keys "#") (call-interactively 'org-agenda-list-stuck-projects))
((equal org-keys "/") (call-interactively 'org-occur-in-agenda-files))
@@ -9492,7 +9491,7 @@ the resulting entry will not be shown. When TEXT is empty, switch to
(goto-char (point-min))
(cl-case type
(anniversary
- (or (re-search-forward "^*[ \t]+Anniversaries" nil t)
+ (or (re-search-forward "^\\*[ \t]+Anniversaries" nil t)
(progn
(or (org-at-heading-p t)
(progn
diff --git a/lisp/org-clock.el b/lisp/org-clock.el
index b8b4f1b..9a8928a 100644
--- a/lisp/org-clock.el
+++ b/lisp/org-clock.el
@@ -1636,9 +1636,10 @@ to, overriding the existing value of `org-clock-out-switch-to-state'."
"\\>"))))
(org-todo org-clock-out-switch-to-state))))))
(force-mode-line-update)
- (message (concat "Clock stopped at %s after "
- (org-duration-from-minutes (+ (* 60 h) m)) "%s")
- te (if remove " => LINE REMOVED" ""))
+ (message (if remove
+ "Clock stopped at %s after %s => LINE REMOVED"
+ "Clock stopped at %s after %s")
+ te (org-duration-from-minutes (+ (* 60 h) m)))
(run-hooks 'org-clock-out-hook)
(unless (org-clocking-p)
(setq org-clock-current-task nil)))))))
@@ -1937,13 +1938,14 @@ Use `\\[org-clock-remove-overlays]' to remove the subtree times."
nil 'local))))
(let* ((h (/ org-clock-file-total-minutes 60))
(m (- org-clock-file-total-minutes (* 60 h))))
- (message (concat (format "Total file time%s: "
- (cond (todayp " for today")
- (customp " (custom)")
- (t "")))
- (org-duration-from-minutes
- org-clock-file-total-minutes)
- " (%d hours and %d minutes)")
+ (message (cond
+ (todayp
+ "Total file time for today: %s (%d hours and %d minutes)")
+ (customp
+ "Total file time (custom): %s (%d hours and %d minutes)")
+ (t
+ "Total file time: %s (%d hours and %d minutes)"))
+ (org-duration-from-minutes org-clock-file-total-minutes)
h m))))
(defvar-local org-clock-overlays nil)
diff --git a/lisp/org-element.el b/lisp/org-element.el
index 3d6f1f6..7af2734 100644
--- a/lisp/org-element.el
+++ b/lisp/org-element.el
@@ -2195,7 +2195,7 @@ containing `:key', `:value', `:begin', `:end', `:post-blank' and
;; this corner case.
(let ((begin (or (car affiliated) (point)))
(post-affiliated (point))
- (key (progn (looking-at "[ \t]*#\\+\\(\\S-+*\\):")
+ (key (progn (looking-at "[ \t]*#\\+\\(\\S-*\\):")
(upcase (match-string-no-properties 1))))
(value (org-trim (buffer-substring-no-properties
(match-end 0) (point-at-eol))))
diff --git a/lisp/org-list.el b/lisp/org-list.el
index 04b3257..9864b18 100644
--- a/lisp/org-list.el
+++ b/lisp/org-list.el
@@ -221,7 +221,7 @@ into
(defcustom org-plain-list-ordered-item-terminator t
"The character that makes a line with leading number an ordered list item.
-Valid values are ?. and ?\). To get both terminators, use t.
+Valid values are ?. and ?\\). To get both terminators, use t.
This variable needs to be set before org.el is loaded. If you
need to make a change while Emacs is running, use the customize
@@ -2629,7 +2629,7 @@ Return t if successful."
(error "Cannot outdent beyond margin")
;; Change bullet if necessary.
(when (and (= (+ top-ind offset) 0)
- (string-match "*"
+ (string-match "\\*"
(org-list-get-bullet beg struct)))
(org-list-set-bullet beg struct
(org-list-bullet-string "-")))
diff --git a/lisp/org-mobile.el b/lisp/org-mobile.el
index 854f7ce..3cfb2c6 100644
--- a/lisp/org-mobile.el
+++ b/lisp/org-mobile.el
@@ -857,11 +857,11 @@ If BEG and END are given, only do this in that region."
(cl-incf cnt-error)
(throw 'next t))
(move-marker bos-marker (point))
- (if (re-search-forward "^** Old value[ \t]*$" eos t)
+ (if (re-search-forward "^\\** Old value[ \t]*$" eos t)
(setq old (buffer-substring
(1+ (match-end 0))
(progn (outline-next-heading) (point)))))
- (if (re-search-forward "^** New value[ \t]*$" eos t)
+ (if (re-search-forward "^\\** New value[ \t]*$" eos t)
(setq new (buffer-substring
(1+ (match-end 0))
(progn (outline-next-heading)
diff --git a/lisp/org-mouse.el b/lisp/org-mouse.el
index 0cca65c..13d88da 100644
--- a/lisp/org-mouse.el
+++ b/lisp/org-mouse.el
@@ -633,7 +633,7 @@ This means, between the beginning of line and the point."
,@(org-mouse-list-options-menu (mapcar 'car org-startup-options)
'org-mode-restart))))
((or (eolp)
- (and (looking-at "\\( \\|\t\\)\\(+:[0-9a-zA-Z_:]+\\)?\\( \\|\t\\)+$")
+ (and (looking-at "\\( \\|\t\\)\\(\\+:[0-9a-zA-Z_:]+\\)?\\( \\|\t\\)+$")
(looking-back " \\|\t" (- (point) 2)
(line-beginning-position))))
(org-mouse-popup-global-menu))
diff --git a/lisp/org-plot.el b/lisp/org-plot.el
index aa34e40..a5635e3 100644
--- a/lisp/org-plot.el
+++ b/lisp/org-plot.el
@@ -336,7 +336,7 @@ line directly before or after the table."
(insert "\n")
(insert-file-contents (plist-get params :script))
(goto-char (point-min))
- (while (re-search-forward "$datafile" nil t)
+ (while (re-search-forward "\\$datafile" nil t)
(replace-match data-file nil nil)))
(insert (org-plot/gnuplot-script data-file num-cols params)))
;; Graph table.
diff --git a/lisp/org-protocol.el b/lisp/org-protocol.el
index 3f48be1..44c6abb 100644
--- a/lisp/org-protocol.el
+++ b/lisp/org-protocol.el
@@ -331,7 +331,7 @@ returned list."
(len 0)
dir
ret)
- (when (string-match "^\\(.*\\)\\(org-protocol:/+[a-zA-z0-9][-_a-zA-z0-9]*:/+\\)\\(.*\\)" trigger)
+ (when (string-match "^\\(.*\\)\\(org-protocol:/+[a-zA-Z0-9][-_a-zA-Z0-9]*:/+\\)\\(.*\\)" trigger)
(setq dir (match-string 1 trigger))
(setq len (length dir))
(setcar l (concat dir (match-string 3 trigger))))
diff --git a/lisp/org-table.el b/lisp/org-table.el
index 509f5ba..fe6e0ed 100644
--- a/lisp/org-table.el
+++ b/lisp/org-table.el
@@ -1746,7 +1746,7 @@ to a number. In the case of a timestamp, increment by days."
(- (org-time-string-to-absolute txt)
(org-time-string-to-absolute txt-up)))
((string-match org-ts-regexp3 txt) 1)
- ((string-match "\\([-+]\\)?\\(?:[0-9]+\\)?\\(?:\.[0-9]+\\)?" txt-up)
+ ((string-match "\\([-+]\\)?[0-9]*\\(?:\\.[0-9]+\\)?" txt-up)
(- (string-to-number txt)
(string-to-number (match-string 0 txt-up))))
(t 1)))
@@ -2040,7 +2040,7 @@ LOCATION instead."
"\n"))))
(defsubst org-table-formula-make-cmp-string (a)
- (when (string-match "\\`$[<>]" a)
+ (when (string-match "\\`\\$[<>]" a)
(let ((arrow (string-to-char (substring a 1))))
;; Fake a high number to make sure this is sorted at the end.
(setq a (org-table-formula-handle-first/last-rc a))
@@ -2088,7 +2088,7 @@ LOCATION is a buffer position, consider the formulas there."
(cond
((not (match-end 2)) m)
;; Is it a column reference?
- ((string-match-p "\\`$\\([0-9]+\\|[<>]+\\)\\'" m) m)
+ ((string-match-p "\\`\\$\\([0-9]+\\|[<>]+\\)\\'" m) m)
;; Since named columns are not possible in
;; LHS, assume this is a named field.
(t (match-string 2 string)))))
@@ -2790,7 +2790,7 @@ known that the table will be realigned a little later anyway."
(cond
((string-match "\\`@-?I+" old-lhs)
(user-error "Can't assign to hline relative reference"))
- ((string-match "\\`$[<>]" old-lhs)
+ ((string-match "\\`\\$[<>]" old-lhs)
(let ((new (org-table-formula-handle-first/last-rc
old-lhs)))
(when (assoc new eqlist)
@@ -3212,7 +3212,8 @@ Parameters get priority."
(setq startline (org-current-line))
(dolist (entry eql)
(let* ((type (cond
- ((string-match "\\`$\\([0-9]+\\|[<>]+\\)\\'" (car entry))
+ ((string-match "\\`\\$\\([0-9]+\\|[<>]+\\)\\'"
+ (car entry))
'column)
((equal (string-to-char (car entry)) ?@) 'field)
(t 'named)))
diff --git a/lisp/org.el b/lisp/org.el
index 4b7830b..db025a1 100644
--- a/lisp/org.el
+++ b/lisp/org.el
@@ -9351,7 +9351,8 @@ prefix argument (`C-u C-u C-u C-c C-w')."
(when (featurep 'org-inlinetask)
(org-inlinetask-remove-END-maybe))
(setq org-markers-to-move nil)
- (message (concat actionmsg " to \"%s\" in file %s: done") (car it) file)))))))
+ (message "%s to \"%s\" in file %s: done" actionmsg
+ (car it) file)))))))
(defun org-refile-goto-last-stored ()
"Go to the location where the last refile was stored."
@@ -19364,7 +19365,7 @@ assumed to be significant there."
(save-excursion
(skip-chars-backward "[ \t]")
(skip-chars-backward "\\\\")
- (looking-at "\\\\\\\\\\($\\|[^\\\\]\\)")))
+ (looking-at "\\\\\\\\\\($\\|[^\\]\\)")))
(defun org-fill-paragraph-with-timestamp-nobreak-p ()
"Non-nil when a new line at point would split a timestamp."
diff --git a/lisp/ox-ascii.el b/lisp/ox-ascii.el
index 25317cb..7917e3d 100644
--- a/lisp/ox-ascii.el
+++ b/lisp/ox-ascii.el
@@ -1472,8 +1472,8 @@ contextual information."
(replace-regexp-in-string
"-" "•"
(replace-regexp-in-string
- "+" "⁃"
- (replace-regexp-in-string "*" "‣" bul))))))))
+ "\\+" "⁃"
+ (replace-regexp-in-string "\\*" "‣" bul))))))))
(indentation (if (eq list-type 'descriptive) org-ascii-quote-margin
(string-width bullet))))
(concat
diff --git a/lisp/ox-latex.el b/lisp/ox-latex.el
index fc3285e..cdcb07a 100644
--- a/lisp/ox-latex.el
+++ b/lisp/ox-latex.el
@@ -1610,7 +1610,7 @@ INFO is a plist used as a communication channel."
(defun org-latex-clean-invalid-line-breaks (data _backend _info)
(replace-regexp-in-string
- "\\(\\end{[A-Za-z0-9*]+}\\|^\\)[ \t]*\\\\\\\\[ \t]*$" "\\1"
+ "\\(\\\\end{[A-Za-z0-9*]+}\\|^\\)[ \t]*\\\\\\\\[ \t]*$" "\\1"
data))
diff --git a/lisp/ox.el b/lisp/ox.el
index 04fb213..e35016f 100644
--- a/lisp/ox.el
+++ b/lisp/ox.el
@@ -3306,7 +3306,7 @@ storing and resolving footnotes. It is created automatically."
(setq value (replace-match "" nil nil value)))))
(lines
(and (string-match
- ":lines +\"\\(\\(?:[0-9]+\\)?-\\(?:[0-9]+\\)?\\)\""
+ ":lines +\"\\([0-9]*-[0-9]*\\)\""
value)
(prog1 (match-string 1 value)
(setq value (replace-match "" nil nil value)))))