1

Is there any way to start emacs with both weekly agenda and todo list at startup? Similar to Doom Emacs shortcut <SPACE> - o - a - a - n (Agenda and all TODO's).

I can't seem to find a way to do this and both of these will overwrite the previous if used together, in separate windows:

(add-hook 'after-init-hook 'org-todo-list)
(add-hook 'after-init-hook 'org-agenda-list)
1
2

If I correctly understood your question, the solution is pretty simple:

(defun emacs-startup-screen ()
  "Display the weekly org-agenda and all todos."
  (org-agenda nil "n"))
(add-hook 'emacs-startup-hook #'emacs-startup-screen)

Instead of the named function emacs-startup-screen, you can also use a lambda function like (lambda () (org-agenda nil "n")), but using lambdas in hooks is not recommended.

1
  • Thank you. I have used "dashboard" since then, but this worked like a charm! – Sergiu Elmi Dec 15 '20 at 14:47

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.