From mboxrd@z Thu Jan 1 00:00:00 1970 From: Bernt Hansen Subject: Re: Setting org-archive-location Date: Sat, 06 Dec 2008 15:28:24 -0500 Message-ID: <87prk5rqtz.fsf@gollum.intra.norang.ca> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1L93lP-00085Z-P1 for emacs-orgmode@gnu.org; Sat, 06 Dec 2008 15:28:31 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1L93lO-000852-7o for emacs-orgmode@gnu.org; Sat, 06 Dec 2008 15:28:31 -0500 Received: from [199.232.76.173] (port=52706 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1L93lO-00084z-2Z for emacs-orgmode@gnu.org; Sat, 06 Dec 2008 15:28:30 -0500 Received: from mho-02-bos.mailhop.org ([63.208.196.179]:56529) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1L93lN-0000xS-QB for emacs-orgmode@gnu.org; Sat, 06 Dec 2008 15:28:29 -0500 In-Reply-To: (David Neu's message of "Sat\, 6 Dec 2008 15\:05\:26 -0500") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: David Neu Cc: emacs-orgmode@gnu.org "David Neu" writes: > Is there any way to get the second part of the org-archive-location > variable, i.e. the part after the colon that corresponds to headline, > to be the headline under which an subtree lies. For example, consider > > * Work > ** Finsh DBMS > *** TODO Define schema > *** TODO Write code > ** Implement API > *** TODO Develop prototype > > * Home > ** Clean garage > *** TODO Buy shelves > *** TODO Install shelves > > For "Finish DBMS", and "Implement API", you might want to have > > (setq org-archive-location (format-time-string > "%%s-%Y-%m-archive.org::* Work" (current-time))) > > but for "Clean garage", you would then want > > (setq org-archive-location (format-time-string > "%%s-%Y-%m-archive.org::* Home" (current-time))) > > Is there any way to achieve this behavior? Set a property under the level 1 headings with the archive location you want ,---- | * Work | :PROPERTIES: | :ARCHIVE: %s_archive::* Work | :END: | ** Finish DBMS | ... | * Home | :PROPERTIES: | :ARCHIVE: %s_archive::* Home | :END: | ** Clean garage | ... `---- -Bernt