From: Rodrigo Amestica <ramestica@gmail.com>
To: emacs-orgmode@gnu.org
Subject: Re: capture template property :kill-buffer does not let me refile
Date: Sun, 27 Oct 2013 12:39:15 -0400 [thread overview]
Message-ID: <ybieh768y8c.wl%ramestica@gmail.com> (raw)
In-Reply-To: <ybifvrp7yhi.wl%ramestica@gmail.com>
please, no body else having the same issue?
I tried to understand in org-refile and org-capture-refile how is that refile
and closing the buffer intermix, but I'm not that lisp proficient :-(
Then I tried providing some code for
org-capture-after-finalize-hook, and
org-after-refile-insert-hook
My idea was to save and close the buffer associated to the file I'm capturing to
from one of those hooks. However, it seems that both hooks are invoked before
the new captured text has been inserted into the buffer. For example, if in the
hook I add code to only select and close the associated buffer then after the
capture process has finished then the buffer appears as modified requiring an
explicit save.
Any hints?
Many thanks,
Rodrigo
emacs 24.3.1
org 8.2.1
At Fri, 25 Oct 2013 18:54:33 -0400,
Rodrigo Amestica wrote:
>
> Hello,
>
> for some days I have been capturing one of my templates using C-c C-w
> (org-capture-refile). This option let's me conveniently select under which exact
> header (within the target file) to insert the new entry.
>
> Leaving the target file buffer alive after inserting a new item is inconvenient
> in my case. So I added ':kill-buffer t' to the template configuration. But doing
> so resulted in that now C-c C-w does not offer me to select anything, the entry
> is simple inserted at the beginning of the file and the buffer is killed.
>
> My template is shown below. Is it actually possible to combine
> org-capture-refile with :kill-buffer?
>
> Thanks,
> Rodrigo
>
> ("t"
> "Template"
> entry
> (file "~/my/file.org")
> "* \n :PROPERTIES:\n :Some: \n :Properties: \n :END:"
> :prepend t :kill-buffer t)
next prev parent reply other threads:[~2013-10-27 16:39 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-10-25 22:54 capture template property :kill-buffer does not let me refile Rodrigo Amestica
2013-10-27 16:39 ` Rodrigo Amestica [this message]
2013-10-28 1:48 ` Rodrigo Amestica
2013-11-06 13:42 ` Bastien
2013-11-06 15:17 ` Rodrigo Amestica
2013-11-06 15:27 ` Bastien
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=ybieh768y8c.wl%ramestica@gmail.com \
--to=ramestica@gmail.com \
--cc=emacs-orgmode@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).