Browse Source

Merge branch 'maint'

Kyle Meyer 3 months ago
parent
commit
d9afed12f4
3 changed files with 8 additions and 7 deletions
  1. 5 4
      lisp/org-datetree.el
  2. 1 1
      lisp/org-pcomplete.el
  3. 2 2
      lisp/org.el

+ 5 - 4
lisp/org-datetree.el

@@ -138,15 +138,16 @@ will be built under the headline at point."
        "^\\*+[ \t]+%d-%02d-\\([0123][0-9]\\) \\w+$"
        year month day))))
 
-(defun org-datetree--find-create (regex year &optional month day insert)
-  "Find the datetree matched by REGEX for YEAR, MONTH, or DAY.
-REGEX is passed to `format' with YEAR, MONTH, and DAY as
+(defun org-datetree--find-create
+    (regex-template year &optional month day insert)
+  "Find the datetree matched by REGEX-TEMPLATE for YEAR, MONTH, or DAY.
+REGEX-TEMPLATE is passed to `format' with YEAR, MONTH, and DAY as
 arguments.  Match group 1 is compared against the specified date
 component.  If INSERT is non-nil and there is no match then it is
 inserted into the buffer."
   (when (or month day)
     (org-narrow-to-subtree))
-  (let ((re (format regex year month day))
+  (let ((re (format regex-template year month day))
 	match)
     (goto-char (point-min))
     (while (and (setq match (re-search-forward re nil t))

+ 1 - 1
lisp/org-pcomplete.el

@@ -93,7 +93,7 @@ The return value is a string naming the thing at point."
       (cons "file-option" nil))
      ;; Link abbreviation.
      ((save-excursion
-	(skip-chars-backward "A-Za-z0-9-_")
+	(skip-chars-backward "-A-Za-z0-9_")
 	(and (eq ?\[ (char-before))
 	     (eq ?\[ (char-before (1- (point))))))
       (cons "link" nil))

+ 2 - 2
lisp/org.el

@@ -17512,7 +17512,7 @@ this numeric value."
     (unless inc (setq inc 1))
     (let ((pos (point))
 	  (beg (skip-chars-backward "-+^/*0-9eE."))
-	  (end (skip-chars-forward "-+^/*0-9eE^.")) nap)
+	  (end (skip-chars-forward "-+^/*0-9eE.")) nap)
       (setq nap (buffer-substring-no-properties
 		 (+ pos beg) (+ pos beg end)))
       (delete-region (+ pos beg) (+ pos beg end))
@@ -19364,7 +19364,7 @@ assumed to be significant there."
 (defun org-fill-line-break-nobreak-p ()
   "Non-nil when a new line at point would create an Org line break."
   (save-excursion
-    (skip-chars-backward "[ \t]")
+    (skip-chars-backward " \t")
     (skip-chars-backward "\\\\")
     (looking-at "\\\\\\\\\\($\\|[^\\]\\)")))