emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[O] Bug: org-capture when :prepend t org-capture-kill removes one char t


From: Adam Faryna
Subject: [O] Bug: org-capture when :prepend t org-capture-kill removes one char too much from target buffer [9.1.7 (9.1.7-18-g2f587d-elpaplus @ /Users/devil/.emacs.d/elpa/org-plus-contrib-20180312/)]
Date: Fri, 23 Mar 2018 16:48:36 +0000

When use org-capture which template that targets file with :prepend t, org-capture-kill
removes one char too much from target buffer, in result next item in target
file looses one of asterisk.

Expected behaviour:
org-capture when used which template which targets file with :prepend t,
org-capture-kill revert buffer back to status before invocation of
org-capture without any data loss from the target buffer.

Emacs  : GNU Emacs 25.3.1 (x86_64-apple-darwin13.4.0, NS appkit-1265.21 Version 10.9.5 (Build 13F1911))
 of 2017-09-12
Package: Org mode version 9.1.7 (9.1.7-18-g2f587d-elpaplus @ /Users/devil/.emacs.d/elpa/org-plus-contrib-20180312/)

current state:
==============
(setq
 org-tab-first-hook '(org-babel-hide-result-toggle-maybe org-babel-header-arg-expand)
 org-shiftleft-final-hook '(windmove-left)
 org-icalendar-combined-agenda-file "/Users/devil/.emacs.d/tmp/org.ics"
 org-speed-command-hook '(org-speed-command-activate org-babel-speed-command-activate)
 org-reverse-note-order t
 org-occur-hook '(org-first-headline-recenter)
 org-metaup-hook '(org-babel-load-in-session-maybe)
 org-icalendar-include-todo t
 org-priority-start-cycle-with-default nil
 org-agenda-scheduled-leaders '("" "")
 org-html-format-drawer-function #[514 "\207" [] 3 "\n\n(fn NAME CONTENTS)"]
 org-log-done 'time
 org-latex-format-inlinetask-function 'org-latex-format-inlinetask-default-function
 org-confirm-shell-link-function 'yes-or-no-p
 org-columns-default-format "%25ITEM(Task) %TODO %3PRIORITY %7Effort %8CLOCKSUM %TAGS"
 org-ascii-format-inlinetask-function 'org-ascii-format-inlinetask-default
 org-icalendar-use-deadline '(event-if-todo)
 org-clock-idle-time 2
 org-track-ordered-property-with-tag t
 org-pretty-entities t
 org-agenda-custom-commands '(("co"
       "TODOs weekly sorted by state, priority, deadline, scheduled, alpha and effort"
       ((agenda "*")
)
       ((org-agenda-overriding-header
"TODOs weekly sorted by state, priority, deadline, scheduled, alpha and effort")
(org-agenda-sorting-strategy
(quote
  (todo-state-down priority-down deadline-down
   scheduled-down alpha-down effort-up)
  )
)
)
       )
      ("cn" "TODOs not sheduled"
       ((tags "-SCHEDULED={.+}/!+TODO|+BLOCKED|+IN-PROCESS|+WAITING")
)
       ((org-agenda-overriding-header "TODOs not scheduled")
(org-agenda-sorting-strategy
(quote (deadline-down priority-down alpha-down effort-up)))
)
       )
      ("cb" "TODOs blocked" ((tags "BLOCKED"))
       ((org-agenda-overriding-header "TODOs blocked")
(org-agenda-sorting-strategy
(quote (priority-down deadline-down alpha-down effort-up)))
)
       )
      ("cc" "TODOs canceled" ((todo "CANCELED"))
       ((org-agenda-overriding-header "TODOs canceled")
(org-agenda-sorting-strategy
(quote (priority-down alpha-down effort-up)))
)
       )
      ("cj" "Journal" ((search ""))
       ((org-agenda-files (list org-journal-dir))
(org-agenda-overriding-header "Journal")
(org-agenda-sorting-strategy (quote (timestamp-down))))
       )
      ("d" "Coprehensive agenda"
       ((tags
"PRIORITY=\"A\"+TODO=\"TODO\"|TODO=\"IN-PROCESS\"|TODO=\"BLOCKED\"|TODO=\"WAITING\""
((org-agenda-skip-function
   (quote
    (or
     (org-agenda-skip-entry-if
      (quote todo)
      (quote done)
      )
     (org-agenda-skip-entry-if
      (quote todo)
      (quote
       ("SOMEDAY")
       )
      )
     (my/org-agenda-skip-if-scheduled-later)
     )
    )
   )
  (org-agenda-overriding-header "High-priority unfinished tasks:")
  (org-agenda-sorting-strategy
   (quote
    (time-up effort-down category-keep alpha-up)
    )
   )
  )
)
(agenda "")
(alltodo ""
((org-agenda-skip-function
   (quote
    (or (my/org-skip-subtree-if-priority 65)
     (my/org-skip-subtree-if-habit)
     (org-agenda-skip-if nil (quote (scheduled deadline)))
     (org-agenda-skip-entry-if (quote todo)
      (quote ("IN-PROCESS" "BLOCKED" "WAITING")))
     )
    )
   )
  (org-agenda-sorting-strategy
   (quote (priority-down effort-down category-keep alpha-up))
   )
  )
)
)
       )
      )
 org-latex-format-headline-function 'org-latex-format-headline-default-function
 org-default-notes-file "/Users/devil/.emacs.d/orgs/notes.org"
 org-clock-in-resume t
 org-capture-templates '(("t" "Todo" entry
  (file "/Users/devil/.emacs.d/agenda/tasks.org.gpg")
  "* TODO %?\n  :PROPERTIES:\n  :CREATED: [%<%Y-%m-%d>]\n  :END:"
  :prepend t)
("p" "Blog post" entry
  (file "/Users/devil/.emacs.d/orgs/blog.org.gpg")
  "* %?\n  :PROPERTIES:\n  :CREATED: [%<%Y-%m-%d>]\n  :END:"
  :prepend t)
("h" "Habit" entry
  (file "/Users/devil/.emacs.d/agenda/tasks.org.gpg")
  "* TODO %?\n  SCHEDULED: <%<%Y-%m-%d %a .+2d/4d>>\n  :PROPERTIES:\n  :CREATED: [%<%Y-%m-%d>]\n  :STYLE: habit\n  :END:" :prepend t)
("j" "Journal" entry
  (file "/Users/devil/.emacs.d/orgs/journal.org.gpg")
  "* [%<%Y-%m-%d>]\n%?" :prepend t :jump-to-captured t)
("n" "Add note to currently clocked entry" plain (clock)
  "- Note taken on %U \\\\ \n  %?")
("c" "Contact" entry (file my/org-contacts-file)
  "* %(org-contacts-template-name)\n  :PROPERTIES:\n  :TITLE:\n  :ALIAS:\n  :COMPANY:\n  :ROLE:\n  :EMAIL: %(org-contacts-template-email)\n  :MOBILE:\n  :WORK_PHONE:\n  :ADDRESS:\n  :URL:\n  :BIRTHDAY:\n  :ITOLD_THEM_EMAIL:\n  :ITOLD_THEM_PHONE:\n  :NOTES:\n  :CREATED: [%<%Y-%m-%d>]\n  :END:")
)
 org-icalendar-use-scheduled '(todo-start event-if-todo)
 org-agenda-include-diary t
 org-clock-out-when-done '("TODO" "BLOCKED" "WAITING")
 org-after-todo-state-change-hook '(org-clock-out-if-current)
 org-latex-format-drawer-function #[514 "\207" [] 3 "\n\n(fn _ CONTENTS)"]
 org-odt-format-headline-function 'org-odt-format-headline-default-function
 org-from-is-user-regexp "\\<Adam Faryna\\>"
 org-icalendar-timezone "Europe/London"
 org-src-mode-hook '(org-src-babel-configure-edit-buffer org-src-mode-configure-edit-buffer)
 org-log-done-with-time nil
 org-agenda-before-write-hook '(org-agenda-add-entry-text)
 org-babel-pre-tangle-hook '(save-buffer)
 org-global-properties '(("Effort_ALL" . "0:05 0:15 0:30 1:00 2:00 4:00"))
 org-mode-hook '(org-clock-load flyspell-prog-mode (lambda nil (hl-line-mode))
org-evil-motion-mode org-evil-command-mode org-evil-mode
#[0 "\300\301\302\303\304$\207"
   [add-hook change-major-mode-hook org-show-block-all append local] 5]
#[0 "\300\301\302\303\304$\207"
   [add-hook change-major-mode-hook org-babel-show-result-all append local]
   5]
org-babel-result-hide-spec org-babel-hide-all-hashes org-eldoc-load)
 org-refile-targets '((nil :maxlevel . 1) (org-agenda-files :maxlevel . 1))
 org-bibtex-headline-format-function #[257 "\300 \236A\207" [:title] 3 "\n\n(fn ENTRY)"]
 org-archive-hook '(org-attach-archive-delete-maybe)
 org-ascii-format-drawer-function #[771 " \207" [] 4 "\n\n(fn NAME CONTENTS WIDTH)"]
 org-odt-format-inlinetask-function 'org-odt-format-inlinetask-default-function
 org-clock-persist t
 org-agenda-file-regexp ".*org(.gpg)?$"
 org-refile-use-outline-path t
 org-clock-in-switch-to-state "IN-PROCESS"
 org-directory "/Users/devil/.emacs.d/orgs"
 org-enforce-todo-dependencies t
 org-cycle-hook '(org-cycle-hide-archived-subtrees org-cycle-hide-drawers
  org-cycle-show-empty-lines org-optimize-window-after-visibility-change)
 org-habit-show-habits-only-for-today nil
 org-shiftup-final-hook '(windmove-up)
 org-lowest-priority 68
 org-clock-persist-query-resume nil
 org-odt-convert-processes '(("unoconv" "unoconv -f %f -o %d %i"))
 org-use-property-inheritance t
 org-blank-before-new-entry nil
 org-todo-keywords '((sequence "TODO(t)" "IN-PROCESS(p)" "BLOCKED(b@/!)" "WAITING(w@/!)"
      "SOMEDAY(s@)" "|" "DONE(d!)" "CANCELED(c@)" "UNDOABLE(u@)")
     )
 org-modules '(org-w3m org-bbdb org-bibtex org-docview org-gnus org-info org-irc org-mhe
       org-rmail org-habit org-collector)
 org-closed-keep-when-no-todo t
 org-odt-preferred-output-format "doc"
 org-clock-report-include-clocking-task t
 org-confirm-elisp-link-function 'yes-or-no-p
 org-metadown-hook '(org-babel-pop-to-session-maybe)
 org-log-into-drawer t
 org-odt-format-drawer-function #[514 "\207" [] 3 "\n\n(fn NAME CONTENTS)"]
 org-icalendar-store-UID t
 org-default-priority 65
 org-shiftdown-final-hook '(windmove-down)
 org-blocker-hook '(org-block-todo-from-children-or-siblings-or-parent)
 org-icalendar-alarm-time 10
 org-html-format-headline-function 'org-html-format-headline-default-function
 org-link-parameters '(("rmail" :follow org-rmail-open :store org-rmail-store-link)
       ("mhe" :follow org-mhe-open :store org-mhe-store-link)
       ("irc" :follow org-irc-visit :store org-irc-store-link)
       ("info" :follow org-info-open :export org-info-export :store
org-info-store-link)
       ("gnus" :follow org-gnus-open :store org-gnus-store-link)
       ("docview" :follow org-docview-open :export org-docview-export :store
org-docview-store-link)
       ("bibtex" :follow org-bibtex-open :store org-bibtex-store-link)
       ("bbdb" :follow org-bbdb-open :export org-bbdb-export :complete
org-bbdb-complete-link :store org-bbdb-store-link)
       ("w3m" :store org-w3m-store-link) ("id" :follow org-id-open)
       ("file+sys") ("file+emacs") ("doi" :follow org--open-doi-link)
       ("elisp" :follow org--open-elisp-link)
       ("file" :complete org-file-complete-link)
       ("ftp" :follow (lambda (path) (browse-url (concat "ftp:" path))))
       ("help" :follow org--open-help-link)
       ("http" :follow (lambda (path) (browse-url (concat "http:" path))))
       ("https" :follow (lambda (path) (browse-url (concat "https:" path))))
       ("mailto" :follow
(lambda (path) (browse-url (concat "mailto:" path))))
       ("news" :follow (lambda (path) (browse-url (concat "news:" path))))
       ("shell" :follow org--open-shell-link))
 org-list-description-max-indent 5
 org-html-format-inlinetask-function 'org-html-format-inlinetask-default-function
 org-agenda-mode-hook '(hl-line-mode)
 org-agenda-files '("/Users/devil/.emacs.d/agenda/shared.org"
    "/Users/devil/.emacs.d/agenda/tasks.org.gpg")
 org-clock-out-hook '(org-clock-remove-empty-clock-drawer)
 org-shiftright-final-hook '(windmove-right)
 org-clock-out-remove-zero-time-clocks t
 org-agenda-skip-scheduled-if-deadline-is-shown t
 org-tag-alist '(("@health" . 104) ("@fun" . 117) ("@career" . 99) ("@family&friends" . 102)
("@love" . 108) ("@wealth" . 119))
 )
-- 
Best Regards,
Adam Faryna
Appdy.net

I prefer to use encrypted email.
My public key fingerprint is F410 95D7 AE78 22C1 0E25  F16A 0876 80C6 DA35 C73A.
Learn how to encrypt your email https://emailselfdefense.fsf.org/en.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]