Search code examples
emacskey-bindings

Disable archiving support in org-mode in emacs


I am hitting the wrong key by mistake in Emacs all the time. This is archiving some parts of my org-mode tree (and Emacs' undo system, combined with org-mode's partial view of the tree, makes understanding what happened, or fixing it, extremely hard).

How can I find and disable all key bindings related to archiving, completely?


Solution

  • To find commands, C-h a (apropos-command) is often helpful. It will ask you for a regex and will return all commands that match the regex. So if you type the following: C-h a ^org-.*archive you will get a list of commands starting with "org-" and containing the word "archive".

    That said, checking the source as @lawlist suggests is of course better as commands are not always named the way one expects, though you here need to sift through not just the commands (ie those that can be bound to key combinations) but also all of the helper functions.

    Other ways to quickly get to source files is, if you know of a specific command, to type C-h k and the key combination. This will bring up the help for that function, and from there you will normally find a button that brings you to the source file contains that command (provided emacs knows where it is).

    There is a sister command to 'command-apropos' which is just named 'apropos'. This will search among all commands, functions and variables.