Here is the evil-org pachage I am using: https://github.com/Somelauw/evil-org-mode.

All I want to is be able to demote/promote a subtree by pressing M-L/H.

I have tried using the way the repo recomends:

(evil-define-key 'normal evil-org-mode-map
             (kbd "M-L") 'outline-demote
             (kbd "M-H") 'outline-promote)

I have tried doing it globally:

(global-set-key (kbd "M-L") 'outline-demote)
(global-set-key (kbd "M-H") 'outline-promote)

I have tried doing it through a whole bunch of different keymaps.

I am unable to change any keybindings surrounding evil-org. They remain default.

Any ideas?

Edit: I am not sure that this actually has anything to do with evil. It may just be that I am unable to unbind keystrokes.

Here is my configuration for org and evil-org

(use-package org
  :ensure t
  (setq org-indent-mode 1)
  (setq org-log-done 'time)
  (setq org-agenda-files (list "~/working/sync/org"))
  (setq org-todo-keywords '((sequence "TODO(t)" "MEET(m)" "|" "DONE(d)" "CANCELLED(c)")))
  (setq org-agenda-window-setup 'only-window)
  (:map global-map
    ("M-a"  . org-agenda)))
(use-package org-bullets
  :ensure t
  :config (add-hook 'org-mode-hook (lambda() (org-bullets-mode 1))))

;;evil-org (use-package evil-org :commands evil-org-mode :after org :init (add-hook 'org-mode-hook 'evil-org-mode) :config (evil-org-set-key-theme '(textobjects insert navigation additional shift todo heading)))

  • How did you configured this module? See github.com/Somelauw/evil-org-mode/blob/master/doc/keythemes.org for explanations. Your keys bindings are already implemented. At least, your function outline-demote is not a good one, try org-shiftmetaleft – Ian Jul 9 at 12:21
  • @Ian org-shiftmetaleft does not work. it only promotes/demotes the top heading, not any of the children. I am not sure why. – marc.soda Jul 12 at 5:42
  • Do you have in your configuration this (evil-org-agenda-set-keys)? Again, how did you configured this package? – Ian Jul 12 at 12:35
  • @Ian see the last edit. Thank you for your help, by the way. – marc.soda Jul 13 at 16:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.