* feature request: C-k safety
@ 2010-06-01 14:51 Scott Otterson
2010-06-01 15:43 ` Scot Becker
2010-06-02 22:19 ` Carsten Dominik
0 siblings, 2 replies; 5+ messages in thread
From: Scott Otterson @ 2010-06-01 14:51 UTC (permalink / raw)
To: emacs-orgmode
[-- Attachment #1.1: Type: text/plain, Size: 876 bytes --]
For what must be the dozenth time, I've just accidentally deleted a large
tree by typing C-k while in a headline.
This is really easy to do because emacs users have "C-k deletes to the end
of the line" worn deeply into their neural pathways -- it's so automatic for
me that the keystroke is close to subconscious. A mistaken C-k is
especially hard to detect because org-mode displays the result exactly like
what your subconscious expects, that is, a collapsed headline is deleted to
the end -- and the tree underneath is wiped out with no noticeable warning.
Feature request: add an option preventing tree deletion with C-k without
user confirmation. Actually, I'd like an option to prevent it period.
If this option is already in there, then you're encouraged to tell me to
RTFM. But then also please tell me where it is, because I can't find it.
Thanks much,
Scott
[-- Attachment #1.2: Type: text/html, Size: 1048 bytes --]
[-- Attachment #2: Type: text/plain, Size: 201 bytes --]
_______________________________________________
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: feature request: C-k safety
2010-06-01 14:51 feature request: C-k safety Scott Otterson
@ 2010-06-01 15:43 ` Scot Becker
2010-06-02 22:19 ` Carsten Dominik
1 sibling, 0 replies; 5+ messages in thread
From: Scot Becker @ 2010-06-01 15:43 UTC (permalink / raw)
To: Scott Otterson; +Cc: emacs-orgmode
Scott,
You asked:
> Feature request: add an option preventing tree deletion with C-k without
> user confirmation. Actually, I'd like an option to prevent it period.
> If this option is already in there, then you're encouraged to tell me to
> RTFM. But then also please tell me where it is, because I can't find it.
In the FAQ, you can find this:
(setq org-special-ctrl-k t) before losing your work.
It's a clever compromise, though I suspect it doesn't give as much
protection as you want.
Here's what it does. From the docstring:
When t, the following will happen while the cursor is in the headline:
- When the cursor is at the beginning of a headline, kill the entire
line and possible the folded subtree below the line.
- When in the middle of the headline text, kill the headline up to the tags.
- When after the headline text, kill the tags.
Scot
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: feature request: C-k safety
2010-06-01 14:51 feature request: C-k safety Scott Otterson
2010-06-01 15:43 ` Scot Becker
@ 2010-06-02 22:19 ` Carsten Dominik
2010-06-03 6:24 ` Scott Otterson
2010-06-03 11:11 ` Juri Krivov
1 sibling, 2 replies; 5+ messages in thread
From: Carsten Dominik @ 2010-06-02 22:19 UTC (permalink / raw)
To: Scott Otterson; +Cc: emacs-orgmode
Hi Scott,
OK, I am giving you a variable org-ctrl-k-protect-subtree to get this
protection, either with a query or by throwing an error.
But: my prediction is that you will set this variable to nil again
soon :D
Let me know how it goes.
Cheers
- Carsten
On Jun 1, 2010, at 4:51 PM, Scott Otterson wrote:
> For what must be the dozenth time, I've just accidentally deleted a
> large tree by typing C-k while in a headline.
>
> This is really easy to do because emacs users have "C-k deletes to
> the end of the line" worn deeply into their neural pathways -- it's
> so automatic for me that the keystroke is close to subconscious. A
> mistaken C-k is especially hard to detect because org-mode displays
> the result exactly like what your subconscious expects, that is, a
> collapsed headline is deleted to the end -- and the tree underneath
> is wiped out with no noticeable warning.
>
> Feature request: add an option preventing tree deletion with C-k
> without user confirmation. Actually, I'd like an option to prevent
> it period.
>
> If this option is already in there, then you're encouraged to tell
> me to RTFM. But then also please tell me where it is, because I
> can't find it.
>
> Thanks much,
>
> Scott
> _______________________________________________
> Emacs-orgmode mailing list
> Please use `Reply All' to send replies to the list.
> Emacs-orgmode@gnu.org
> http://lists.gnu.org/mailman/listinfo/emacs-orgmode
- Carsten
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: feature request: C-k safety
2010-06-02 22:19 ` Carsten Dominik
@ 2010-06-03 6:24 ` Scott Otterson
2010-06-03 11:11 ` Juri Krivov
1 sibling, 0 replies; 5+ messages in thread
From: Scott Otterson @ 2010-06-03 6:24 UTC (permalink / raw)
To: Carsten Dominik; +Cc: emacs-orgmode
[-- Attachment #1.1: Type: text/plain, Size: 175 bytes --]
Scot, Anthony and Carsten,
Thanks a ton for the help (and mods). I'll try out these two approaches to
protecting me from myself and see which one I like best.
Scott
>
>
>
[-- Attachment #1.2: Type: text/html, Size: 531 bytes --]
[-- Attachment #2: Type: text/plain, Size: 201 bytes --]
_______________________________________________
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: feature request: C-k safety
2010-06-02 22:19 ` Carsten Dominik
2010-06-03 6:24 ` Scott Otterson
@ 2010-06-03 11:11 ` Juri Krivov
1 sibling, 0 replies; 5+ messages in thread
From: Juri Krivov @ 2010-06-03 11:11 UTC (permalink / raw)
To: Carsten Dominik; +Cc: emacs-orgmode, Scott Otterson
[-- Attachment #1.1: Type: text/plain, Size: 1515 bytes --]
On Thu, Jun 3, 2010 at 12:19 AM, Carsten Dominik
<carsten.dominik@gmail.com>wrote:
> Hi Scott,
>
> OK, I am giving you a variable org-ctrl-k-protect-subtree to get this
> protection, either with a query or by throwing an error.
>
> But: my prediction is that you will set this variable to nil again soon :D
>
LoL!
Actually, I think is a gread idea, and I will test it also. Probably error
will
be much better than query. Thank you Scott and Carsten.
Greetings
Juri
>
> Let me know how it goes.
>
> Cheers
>
> - Carsten
>
>
> On Jun 1, 2010, at 4:51 PM, Scott Otterson wrote:
>
> For what must be the dozenth time, I've just accidentally deleted a large
>> tree by typing C-k while in a headline.
>>
>> This is really easy to do because emacs users have "C-k deletes to the end
>> of the line" worn deeply into their neural pathways -- it's so automatic for
>> me that the keystroke is close to subconscious. A mistaken C-k is
>> especially hard to detect because org-mode displays the result exactly like
>> what your subconscious expects, that is, a collapsed headline is deleted to
>> the end -- and the tree underneath is wiped out with no noticeable warning.
>>
>> Feature request: add an option preventing tree deletion with C-k without
>> user confirmation. Actually, I'd like an option to prevent it period.
>>
>> If this option is already in there, then you're encouraged to tell me to
>> RTFM. But then also please tell me where it is, because I can't find it.
>>
>> Thanks much,
>>
>> Scott
>>
>
[-- Attachment #1.2: Type: text/html, Size: 2264 bytes --]
[-- Attachment #2: Type: text/plain, Size: 201 bytes --]
_______________________________________________
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2010-06-03 11:12 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-06-01 14:51 feature request: C-k safety Scott Otterson
2010-06-01 15:43 ` Scot Becker
2010-06-02 22:19 ` Carsten Dominik
2010-06-03 6:24 ` Scott Otterson
2010-06-03 11:11 ` Juri Krivov
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).