From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Leo Newsgroups: gmane.emacs.bugs Subject: bug#6999: 23.2; [PATCH] appt ignores included diary files Date: Wed, 08 Sep 2010 13:31:42 +0100 Message-ID: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: dough.gmane.org 1283949621 17198 80.91.229.12 (8 Sep 2010 12:40:21 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Wed, 8 Sep 2010 12:40:21 +0000 (UTC) To: 6999@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed Sep 08 14:40:19 2010 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1OtJwp-0002RZ-E0 for geb-bug-gnu-emacs@m.gmane.org; Wed, 08 Sep 2010 14:40:19 +0200 Original-Received: from localhost ([127.0.0.1]:53774 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OtJwo-0004x1-E5 for geb-bug-gnu-emacs@m.gmane.org; Wed, 08 Sep 2010 08:40:18 -0400 Original-Received: from [140.186.70.92] (port=34992 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OtJwh-0004wn-5J for bug-gnu-emacs@gnu.org; Wed, 08 Sep 2010 08:40:13 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OtJwg-0004jq-0m for bug-gnu-emacs@gnu.org; Wed, 08 Sep 2010 08:40:11 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:37335) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OtJwf-0004jm-UF for bug-gnu-emacs@gnu.org; Wed, 08 Sep 2010 08:40:09 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1OtJmt-0002El-Mk; Wed, 08 Sep 2010 08:30:03 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Leo Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 08 Sep 2010 12:30:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 6999 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.12839489958574 (code B ref -1); Wed, 08 Sep 2010 12:30:03 +0000 Original-Received: (at submit) by debbugs.gnu.org; 8 Sep 2010 12:29:55 +0000 Original-Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OtJmk-0002EF-Lc for submit@debbugs.gnu.org; Wed, 08 Sep 2010 08:29:54 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OtJmi-0002E9-So for submit@debbugs.gnu.org; Wed, 08 Sep 2010 08:29:53 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OtJoZ-0003Lg-Pu for submit@debbugs.gnu.org; Wed, 08 Sep 2010 08:31:51 -0400 Original-Received: from lists.gnu.org ([199.232.76.165]:35718) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OtJoZ-0003Lc-Mz for submit@debbugs.gnu.org; Wed, 08 Sep 2010 08:31:47 -0400 Original-Received: from [140.186.70.92] (port=34999 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OtJoY-0003vn-B7 for bug-gnu-emacs@gnu.org; Wed, 08 Sep 2010 08:31:47 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OtJoX-0003LM-Cu for bug-gnu-emacs@gnu.org; Wed, 08 Sep 2010 08:31:46 -0400 Original-Received: from ppsw-30.csi.cam.ac.uk ([131.111.8.130]:39071) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OtJoX-0003LA-94 for bug-gnu-emacs@gnu.org; Wed, 08 Sep 2010 08:31:45 -0400 X-Cam-AntiVirus: no malware found X-Cam-SpamDetails: not scanned X-Cam-ScannerInfo: http://www.cam.ac.uk/cs/email/scanner/ Original-Received: from cpc1-cmbg13-0-0-cust596.5-4.cable.virginmedia.com ([86.9.122.85]:50893 helo=Victoria.local) by ppsw-30.csi.cam.ac.uk (smtp.hermes.cam.ac.uk [131.111.8.156]:587) with esmtpsa (PLAIN:sl392) (TLSv1:DHE-RSA-AES128-SHA:128) id 1OtJoV-0003KB-f0 (Exim 4.72) for bug-gnu-emacs@gnu.org (return-path ); Wed, 08 Sep 2010 13:31:43 +0100 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Wed, 08 Sep 2010 08:30:03 -0400 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:40037 Archived-At: When the main diary file includes other diary files. File saving in the included does no appt-check, which means if one adds appointments directly into the included file, they will not be added by appt-update-list. One simple solution is to make appt-update-list do appt-check if major mode is diary-mode. Then users can open included files in diary mode and add appointments. diff --git a/lisp/calendar/appt.el b/lisp/calendar/appt.el index 3573c95..818fee4 100644 --- a/lisp/calendar/appt.el +++ b/lisp/calendar/appt.el @@ -660,7 +660,8 @@ hour and minute parts." (defun appt-update-list () "If the current buffer is visiting the diary, update appointments. This function is intended for use with `write-file-functions'." - (and (string-equal buffer-file-name (expand-file-name diary-file)) + (and (or (string-equal buffer-file-name (expand-file-name diary-file)) + (eq major-mode 'diary-mode)) appt-timer (let ((appt-display-diary nil)) (appt-check t)))