]> git.eshelyaron.com Git - emacs.git/commitdiff
Update to Org 9.5.1-31-ga18849
authorKyle Meyer <kyle@kyleam.com>
Sat, 18 Dec 2021 18:50:40 +0000 (13:50 -0500)
committerKyle Meyer <kyle@kyleam.com>
Sat, 18 Dec 2021 18:50:40 +0000 (13:50 -0500)
lisp/org/ob-tangle.el
lisp/org/org-agenda.el
lisp/org/org-habit.el
lisp/org/org-version.el
lisp/org/org.el

index 2dd1d031cb2c59880c1ea0bca6a665fb36b38f59..8ed7002ef6521306255007ff1bd9d8fc149cbd87 100644 (file)
@@ -179,15 +179,14 @@ source code blocks by languages matching a regular expression.
 
 Return a list whose CAR is the tangled file name."
   (interactive "fFile to tangle: \nP")
-  (let ((visited-p (find-buffer-visiting (expand-file-name file)))
-       to-be-removed)
+  (let* ((visited (find-buffer-visiting file))
+         (buffer (or visited (find-file-noselect file))))
     (prog1
-       (save-window-excursion
-         (find-file file)
-         (setq to-be-removed (current-buffer))
-         (mapcar #'expand-file-name (org-babel-tangle nil target-file lang-re)))
-      (unless visited-p
-       (kill-buffer to-be-removed)))))
+        (with-current-buffer buffer
+          (org-with-wide-buffer
+           (mapcar #'expand-file-name
+                   (org-babel-tangle nil target-file lang-re))))
+      (unless visited (kill-buffer buffer)))))
 
 (defun org-babel-tangle-publish (_ filename pub-dir)
   "Tangle FILENAME and place the results in PUB-DIR."
index 354f408679cc7ece16289f98584050649ae5cd53..59bdd5b0edb4de94aa2a9f162d5d1b558d547659 100644 (file)
@@ -6765,7 +6765,7 @@ Any match of REMOVE-RE will be removed from TXT."
            (setq duration (- (org-duration-to-minutes s2)
                              (org-duration-to-minutes s1))))
           ;; Format S1 and S2 for display.
-         (when s1 (setq s1 (org-get-time-of-day s1 'overtime)))
+         (when s1 (setq s1 (format "%5s" (org-get-time-of-day s1 'overtime))))
          (when s2 (setq s2 (org-get-time-of-day s2 'overtime))))
        (when (string-match org-tag-group-re txt)
          ;; Tags are in the string
index a355d8e5faf3e1347da08231ec381d82ac0ef988..3ce806855c58eef5e72cf79ca10f4e515d07da2c 100644 (file)
@@ -428,7 +428,8 @@ current time."
     (save-excursion
       (goto-char (if line (point-at-bol) (point-min)))
       (while (not (eobp))
-       (let ((habit (get-text-property (point) 'org-habit-p)))
+       (let ((habit (get-text-property (point) 'org-habit-p))
+              (invisible-prop (get-text-property (point) 'invisible)))
          (when habit
            (move-to-column org-habit-graph-column t)
            (delete-char (min (+ 1 org-habit-preceding-days
@@ -439,7 +440,12 @@ current time."
              habit
              (time-subtract moment (days-to-time org-habit-preceding-days))
              moment
-             (time-add moment (days-to-time org-habit-following-days))))))
+             (time-add moment (days-to-time org-habit-following-days))))
+            ;; Inherit invisible state of hidden entries.
+            (when invisible-prop
+              (put-text-property
+               (- (point) org-habit-graph-column) (point)
+               'invisible invisible-prop))))
        (forward-line)))))
 
 (defun org-habit-toggle-habits ()
index b009b9691fd646046aa55e4f2e9786e5c62a065c..514f82ea4a50411e4b0eae23475baa2fc3808749 100644 (file)
@@ -11,7 +11,7 @@ Inserted by installing Org mode or when a release is made."
 (defun org-git-version ()
   "The Git version of Org mode.
 Inserted by installing Org or when a release is made."
-   (let ((org-git-version "release_9.5.1-25-g9ca3bc"))
+   (let ((org-git-version "release_9.5.1-31-ga18849"))
      org-git-version))
 \f
 (provide 'org-version)
index 00bbc0768811a7b80e2f02a264fc06f331f04883..f784369f95f58a30c3dffc0cdc98c2a904d63a0e 100644 (file)
@@ -6905,7 +6905,7 @@ frame is not changed."
       (setq beg (point)
            heading (org-get-heading 'no-tags))
       (org-end-of-subtree t t)
-      (when (org-at-heading-p) (backward-char 1))
+      (when (and (not (eobp)) (org-at-heading-p)) (backward-char 1))
       (setq end (point)))
     (when (and (buffer-live-p org-last-indirect-buffer)
               (not (eq org-indirect-buffer-display 'new-frame))