From debbugs-submit-bounces@debbugs.gnu.org Sun Mar 06 14:58:13 2011 Received: (at submit) by debbugs.gnu.org; 6 Mar 2011 19:58:13 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PwK5k-0001Wc-B8 for submit@debbugs.gnu.org; Sun, 06 Mar 2011 14:58:12 -0500 Received: from eggs.gnu.org ([140.186.70.92]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PwJz4-0001Md-LV for submit@debbugs.gnu.org; Sun, 06 Mar 2011 14:51:19 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PwJyy-0004DJ-Qh for submit@debbugs.gnu.org; Sun, 06 Mar 2011 14:51:13 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_LOW, T_DKIM_INVALID, T_TO_NO_BRKTS_FREEMAIL autolearn=unavailable version=3.3.1 Received: from lists.gnu.org ([199.232.76.165]:37924) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PwJyy-0004D9-Kw for submit@debbugs.gnu.org; Sun, 06 Mar 2011 14:51:12 -0500 Received: from [140.186.70.92] (port=36739 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PwJyx-0001ab-Bn for bug-gnu-emacs@gnu.org; Sun, 06 Mar 2011 14:51:12 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PwJyv-0004BT-RU for bug-gnu-emacs@gnu.org; Sun, 06 Mar 2011 14:51:11 -0500 Received: from mail-vw0-f41.google.com ([209.85.212.41]:55175) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PwJyv-0004At-PB; Sun, 06 Mar 2011 14:51:09 -0500 Received: by vws13 with SMTP id 13so4049033vws.0 for ; Sun, 06 Mar 2011 11:51:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:sender:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type; bh=dg5oOqGqdnsz7RcU4k6IZacGVQydPxrigD5ojFiQdQA=; b=hV95dKVuKQC2t/tTfWB8B8OlgGU8tTTeDyH1cVYh+ZS+doGvlN5fOw2o6c2AeK6+A6 X3zTRzWSbA18PFswDm1Jr7Ja63jSvrWoMOnSAd9tkgsAqnPDByXizlEGSiWVQV+AtRPh Qa0c/i3kUkyuOhxW7hMd2jJgroCRj/mhUPCTY= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:from:date:x-google-sender-auth:message-id :subject:to:cc:content-type; b=XdlMC02nk6d95LocvwKSakA+YYG9ueLJ6BL/y3AUUxi4QLMLr9EmUukVJNsq9PcqI7 CLWhzrgHdMdxA1caWq9RoCGpN1hNg0kA2aMZw7AlFLnsOjcl2v1JRvxpAcugPGILlhrz zVfMNhlo5M/WIyVo31M3k4fEsV+tDUJ0STz2g= Received: by 10.52.178.164 with SMTP id cz4mr4389730vdc.42.1299441068130; Sun, 06 Mar 2011 11:51:08 -0800 (PST) MIME-Version: 1.0 Received: by 10.220.181.133 with HTTP; Sun, 6 Mar 2011 11:50:48 -0800 (PST) From: Edward Reingold Date: Sun, 6 Mar 2011 13:50:48 -0600 X-Google-Sender-Auth: GgDXPVItPDpGUKsLI7cx73yHTEk Message-ID: Subject: Minor improvement for diary-yahrzeit To: bug-gnu-emacs@gnu.org Content-Type: text/plain; charset=ISO-8859-1 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 199.232.76.165 X-Spam-Score: -5.9 (-----) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Sun, 06 Mar 2011 14:58:11 -0500 Cc: Glenn Morris X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -5.9 (-----) The code below includes the one day correction needed if the death is after local sunset. This change makes the code parallel to the code for diary-hebrew-birthday that I sent last week. (defun diary-yahrzeit (death-month death-day death-year &optional after-sunset) "Yahrzeit diary entry--entry applies if date is yahrzeit or the day before. Parameters are DEATH-MONTH, DEATH-DAY, DEATH-YEAR; the diary entry is assumed to be the name of the person. Date of death is on the *civil* calendar; although the date of death is specified by the civil calendar, the proper Hebrew calendar yahrzeit is determined. NOTE: If the death occurred after local sunset on the given civil date, the following civil date corresponds to the Hebrew date of death--the optional parameter AFTER-SUNSET does this correction when t. If `european-calendar-style' is t, the order of the parameters is changed to DEATH-DAY, DEATH-MONTH, DEATH-YEAR." (let* ((h-date (calendar-hebrew-from-absolute (+ (calendar-absolute-from-gregorian (if european-calendar-style (list death-day death-month death-year) (list death-month death-day death-year))) (if after-sunset 1 0)))) (h-month (extract-calendar-month h-date)) (h-day (extract-calendar-day h-date)) (h-year (extract-calendar-year h-date)) (d (calendar-absolute-from-gregorian date)) (yr (extract-calendar-year (calendar-hebrew-from-absolute d))) (diff (- yr h-year)) (y (hebrew-calendar-yahrzeit h-date yr))) (if (and (> diff 0) (or (= y d) (= y (1+ d)))) (format "Yahrzeit of %s%s: %d%s anniversary" entry (if (= y d) "" " (evening)") diff (cond ((= (% diff 10) 1) "st") ((= (% diff 10) 2) "nd") ((= (% diff 10) 3) "rd") (t "th")))))) From debbugs-submit-bounces@debbugs.gnu.org Mon Mar 07 02:47:51 2011 Received: (at 8190-done) by debbugs.gnu.org; 7 Mar 2011 07:47:51 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PwVAV-0003cd-7W for submit@debbugs.gnu.org; Mon, 07 Mar 2011 02:47:51 -0500 Received: from fencepost.gnu.org ([140.186.70.10]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PwVAT-0003cK-3a for 8190-done@debbugs.gnu.org; Mon, 07 Mar 2011 02:47:49 -0500 Received: from localhost ([127.0.0.1]:35519) by fencepost.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PwVAN-0001xA-Ln; Mon, 07 Mar 2011 02:47:43 -0500 From: Glenn Morris To: 8190-done@debbugs.gnu.org Subject: Re: Minor improvement for diary-yahrzeit References: X-Spook: satellite imagery JPL sweep anthrax Forte import airframe X-Ran: {6[X#E!Bkz`(K97B8Ocg@qNMCx+m0<`sC#G>GXB1Og,0\b+ X-Hue: blue X-Debbugs-No-Ack: yes X-Attribution: GM Date: Mon, 07 Mar 2011 02:47:43 -0500 In-Reply-To: (Edward Reingold's message of "Sun, 6 Mar 2011 13:50:48 -0600") Message-ID: User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Score: -6.3 (------) X-Debbugs-Envelope-To: 8190-done X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.3 (------) Version: 24.1 Applied; thanks. From unknown Fri Jun 20 07:16:37 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Mon, 04 Apr 2011 11:24:04 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator