From mboxrd@z Thu Jan 1 00:00:00 1970 From: Nick Dokos Subject: Re: org google weather Date: Fri, 04 Mar 2011 17:05:55 -0500 Message-ID: <6122.1299276355@alphaville.usa.hp.com> References: <87oc5rlwc4.wl%lists@700c.org> <4D70A577.4000509@manor-farm.org> <87lj0uinin.wl%lists@700c.org> Reply-To: nicholas.dokos@hp.com Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from [140.186.70.92] (port=48187 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Pvd8M-000110-SA for emacs-orgmode@gnu.org; Fri, 04 Mar 2011 17:06:03 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Pvd8H-0005TX-HU for emacs-orgmode@gnu.org; Fri, 04 Mar 2011 17:06:02 -0500 Received: from g4t0017.houston.hp.com ([15.201.24.20]:32386) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Pvd8H-0005TQ-CU for emacs-orgmode@gnu.org; Fri, 04 Mar 2011 17:05:57 -0500 In-Reply-To: Message from Simon Brown of "Fri\, 04 Mar 2011 21\:28\:16 GMT." <87lj0uinin.wl%lists@700c.org> 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: Simon Brown Cc: nicholas.dokos@hp.com, emacs-orgmode@gnu.org Simon Brown wrote: > At Fri, 04 Mar 2011 08:40:23 +0000, > Ian Barton wrote: > > On 03/03/11 21:37, Simon Brown wrote: > > > Has anybody tried adding the functionality of %%(diary-sunrise-sunset) > > > (sunrise, sunset time and daylight hours) to the google weather code? > > I just have something like: > >=20 > > #+CATEGORY: Day/Year > > &%%(diary-day-of-year) > > #+CATEGORY: Sunrise > > &%%(diary-sunrise-sunset) >=20 > That's where I am at the moment, with the weather forecast, sunrise > and sunset times on different lines. I was wondering if the two could > be integrated to make a one line weather forecast, sunrise and sunset > times. ? >=20 > eg. > Location: (icon) Chance of Rain, [-1,6] =E2=84=83, Sunrise 0658 Sunset 17= 59 1101 hrs of daylight >=20 Just write your own function to take the individual results and concatenate= them, e.g. --8<---------------cut here---------------start------------->8--- (defun full-catastrophe () (format "%s :: %s" (org-google-weather) (diary-sunrise-sunset))) --8<---------------cut here---------------end--------------->8--- and add=20 --8<---------------cut here---------------start------------->8--- %%(full-catastrophe) --8<---------------cut here---------------end--------------->8--- to some agenda file. Nick