From mboxrd@z Thu Jan 1 00:00:00 1970 From: Bastien Subject: Re: Patch to get clocktable to split on week boundraries Date: Fri, 15 Mar 2013 11:50:11 +0100 Message-ID: <87ip4tj5ss.fsf@bzg.ath.cx> References: Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Return-path: Received: from eggs.gnu.org ([208.118.235.92]:57886) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UGSDW-00016v-Dt for emacs-orgmode@gnu.org; Fri, 15 Mar 2013 06:50:32 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UGSDV-0000rv-GP for emacs-orgmode@gnu.org; Fri, 15 Mar 2013 06:50:30 -0400 Received: from mail-wi0-x234.google.com ([2a00:1450:400c:c05::234]:53091) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UGSDV-0000ro-A6 for emacs-orgmode@gnu.org; Fri, 15 Mar 2013 06:50:29 -0400 Received: by mail-wi0-f180.google.com with SMTP id hi8so348935wib.13 for ; Fri, 15 Mar 2013 03:50:28 -0700 (PDT) In-Reply-To: (Peder Stray's message of "Mon, 4 Mar 2013 15:44:24 +0100") 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: Peder Stray Cc: emacs-orgmode@gnu.org Hi Peder, Peder Stray writes: > When calling clocktable with :block *month and :step week it splits > into block 7 days long starting from the first day in the month... > that's not very useful I think, so here is a patch making it split > the month into weeks starting on mondays.  The first and last week > will be clipped to only include the days in the selected month and as > such will not contain the full 7 days of those weeks. thanks for this idea and for the patch. I just pushed a different implementation, allowing a new :mstart parameter for clocktables, similar to the already existing :wstart parameter. The default for :wstart (the week starting day) is 1, for monday. The default for :mstart (the month starting day) is 1, for the first day of the month. So the new default for e.g., #+BEGIN: clocktable :block month :step week #+END is to start on the 1st of the month (ignoring :wstart) and to continue with weeks starting on mondays. If you use #+BEGIN: clocktable :block month :step week :wstart 2 :mstart 3 #+END it will start the report on the 3rd of the month, and continue the weekly steps starting from tuesdays. Thanks for this idea and for the patch! -- Bastien