From: Ihor Radchenko <yantar92@posteo.net>
To: Dan Drake <dan.drake@gmail.com>
Cc: "Rudolf Adamkovič" <rudolf@adamkovic.org>, emacs-orgmode@gnu.org
Subject: Re: org-cut-subtree should respect org-ctrl-k-protect-subtree
Date: Sun, 20 Oct 2024 12:46:08 +0000 [thread overview]
Message-ID: <87jze3q6wf.fsf@localhost> (raw)
In-Reply-To: <CAKqbAeELYJSa0yKTaK8WhYUtoZFL7d108uiTVpKOE9mq+7oeEA@mail.gmail.com>
Dan Drake <dan.drake@gmail.com> writes:
> I like that idea. It's consistent, uses "prior art", so to speak, and most
> of all , archiving involves cutting the subtree, so it's a very similar
> change to the buffer / structure.
I looked into doing this using a very simple variant of the command:
(defun org-cut-subtree-with-confirmation (&optional n)
"Cut the current subtree into the clipboard with prompt.
Like `org-cut-subtree', but ask for confirmation before killing the
subtree."
(interactive "p")
(when (yes-or-no-p "Really cut current subtree?")
(funcall-interactively #'org-cut-subtree n)))
However, unless we change the Org defaults (which I see no reason to),
this new command will need to be used by users who are specifically
seeking for such functionality.
As you see, this thread got no replies from other people interested in
the same functionality for over a month (Rudolf was interested in
something more generic).
Considering how simple the command is, I now think that the interested
users can trivially implement it themselves (as you did). I feel that
there is not much benefit adding such a command to Org mode itself.
--
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>
next prev parent reply other threads:[~2024-10-20 12:45 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-27 13:10 org-cut-subtree should respect org-ctrl-k-protect-subtree Dan Drake
2024-08-27 14:15 ` Rudolf Adamkovič
2024-08-28 11:46 ` Dan Drake
2024-08-29 10:39 ` Rudolf Adamkovič
2024-09-01 16:20 ` Ihor Radchenko
2024-09-01 18:49 ` Dan Drake
2024-09-15 12:46 ` Ihor Radchenko
2024-09-17 23:36 ` Dan Drake
2024-10-20 12:46 ` Ihor Radchenko [this message]
2024-09-03 23:09 ` Rudolf Adamkovič
2024-09-22 16:35 ` Ihor Radchenko
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87jze3q6wf.fsf@localhost \
--to=yantar92@posteo.net \
--cc=dan.drake@gmail.com \
--cc=emacs-orgmode@gnu.org \
--cc=rudolf@adamkovic.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 external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.