From mboxrd@z Thu Jan 1 00:00:00 1970 From: Alexander Baier Subject: Re: loading all agenda files at startup Date: Wed, 30 Apr 2014 10:58:43 +0200 Message-ID: <87lhunchx8.fsf@gmail.com> References: <87fvkvdycb.fsf@ericabrahamsen.net> <87fvkvfcoq.fsf@tanger.home> <87fvkvi4u6.fsf@ericabrahamsen.net> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:46804) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WfQN8-0008UE-1x for emacs-orgmode@gnu.org; Wed, 30 Apr 2014 05:00:15 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WfQMy-0005Fw-7J for emacs-orgmode@gnu.org; Wed, 30 Apr 2014 05:00:09 -0400 Received: from mail-qc0-x22b.google.com ([2607:f8b0:400d:c01::22b]:44057) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WfQMy-0005Fm-2S for emacs-orgmode@gnu.org; Wed, 30 Apr 2014 05:00:00 -0400 Received: by mail-qc0-f171.google.com with SMTP id c9so1522841qcz.2 for ; Wed, 30 Apr 2014 01:59:58 -0700 (PDT) In-Reply-To: <87fvkvi4u6.fsf@ericabrahamsen.net> (Eric Abrahamsen's message of "Wed, 30 Apr 2014 16:44:49 +0800") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Eric Abrahamsen Cc: emacs-orgmode@gnu.org On 2014-04-30 10:44 Eric Abrahamsen wrote: > Daimrod writes: > >> Eric Abrahamsen writes: >> >> Hi Eric, >> >>> I've got a few top-level user commands, related to org, that load at >>> startup. Specifically org-agenda and org-ido-switchb are bound to keys >>> that are available after emacs starts up. Before Org loads properly, >>> however, things like the agenda file list and the list of valid tags and >>> TODO keywords are unavailable. That makes it hard to boot emacs and go >>> directly into a call to `org-todo-list': the TODO keywords aren't loaded >>> yet. >>> >>> I've looked into this before but couldn't find a single function that >>> would "boot" my local data. `org-agenda-files' reads the file list, but >>> it doesn't actually parse the files and do all the setup routines. >>> >>> Is there a single-function entry point that I could put in my init >>> files, that would get me where I want to be? ie, in a state as though >>> `org-agenda' had already been called, though it hasn't yet? >> >> I call `org-agenda-list' in my `after-init-hook' but it is not "silent", >> that is, it displays the agenda list. >> >> Best, > > Right, just calling the agenda directly will certainly solve the issue, > and I suppose as a member of the Org faithful I should be booting to the > agenda! But it would be nice to get the same effect, but be left in > *scratch*... Maybe hacking around it with something like the following in 'org-agenda-after-show-hook' or some similar hook? #+begin_src emacs-lisp (defun my-switch-to-sratch () (switch-to-buffer "*scratch*") (delete-other-windows)) #+end_src HTH, -- Alexander Baier