]> git.bundesbrandschatzamt.de Git - emacsconfig.git/commitdiff
fix for bba-export-jira-org
authorAndreas Gerler <baronNOSPAMbundesbrandschatzamt.de>
Tue, 6 Dec 2016 10:12:37 +0000 (11:12 +0100)
committerAndreas Gerler <baronNOSPAMbundesbrandschatzamt.de>
Tue, 6 Dec 2016 10:12:37 +0000 (11:12 +0100)
- without region write-region saves the whole buffer even if it's narrowed.

Signed-off-by: Andreas Gerler <baronNOSPAMbundesbrandschatzamt.de>
bba.org

diff --git a/bba.org b/bba.org
index 73db22627cfad3fe563227b28f1d750b51aae758..f26486c5bfe0db007acdddb2a930c19bd067f0b5 100644 (file)
--- a/bba.org
+++ b/bba.org
@@ -878,7 +878,9 @@ the jira ticket:
            (description (last (split-string (if (match-end 3)
                                                            (match-string-no-properties 3)
                                               (match-string-no-properties 1)) ":"))))
-       (write-region nil nil (concat "/tmp/" (car description) ".org") nil nil )
+       (mark-whole-buffer)
+       (write-region (mark) (point) (concat "/tmp/" (car description) ".org") nil nil )
+    (deactivate-mark)
        (if (string-equal system-type "darwin")(shell-command "open /tmp/"))
        )))
   )