From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Kevin Rodgers Newsgroups: gmane.emacs.help Subject: Re: diary-mail-entries Date: Tue, 20 Mar 2007 22:45:19 -0600 Message-ID: References: <20070320214922.GD16535@relwi.unibe.ch> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit X-Trace: sea.gmane.org 1174452362 507 80.91.229.12 (21 Mar 2007 04:46:02 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 21 Mar 2007 04:46:02 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed Mar 21 05:45:57 2007 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1HTshw-0006Gi-K3 for geh-help-gnu-emacs@m.gmane.org; Wed, 21 Mar 2007 05:45:56 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HTsjZ-0001nl-Ue for geh-help-gnu-emacs@m.gmane.org; Tue, 20 Mar 2007 23:47:37 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1HTsjO-0001nU-R7 for help-gnu-emacs@gnu.org; Wed, 21 Mar 2007 00:47:26 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1HTsjM-0001nI-G3 for help-gnu-emacs@gnu.org; Wed, 21 Mar 2007 00:47:25 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HTsjM-0001nF-8u for help-gnu-emacs@gnu.org; Tue, 20 Mar 2007 23:47:24 -0500 Original-Received: from main.gmane.org ([80.91.229.2] helo=ciao.gmane.org) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1HTshi-00089g-21 for help-gnu-emacs@gnu.org; Wed, 21 Mar 2007 00:45:42 -0400 Original-Received: from list by ciao.gmane.org with local (Exim 4.43) id 1HTshY-00073c-4l for help-gnu-emacs@gnu.org; Wed, 21 Mar 2007 05:45:32 +0100 Original-Received: from c-67-162-159-170.hsd1.co.comcast.net ([67.162.159.170]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 21 Mar 2007 05:45:32 +0100 Original-Received: from kevin.d.rodgers by c-67-162-159-170.hsd1.co.comcast.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 21 Mar 2007 05:45:32 +0100 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 68 Original-X-Complaints-To: usenet@sea.gmane.org X-Gmane-NNTP-Posting-Host: c-67-162-159-170.hsd1.co.comcast.net User-Agent: Thunderbird 1.5.0.10 (Macintosh/20070221) In-Reply-To: <20070320214922.GD16535@relwi.unibe.ch> X-detected-kernel: Linux 2.6, seldom 2.4 (older, 4) X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:42071 Archived-At: sven.bretfeld@gmx.ch wrote: > Hello list > > I'm trying to set up a cron job sending me the entries of the Emacs > diary every morning, just as described in > > http://www.emacswiki.org/cgi-bin/wiki/DiaryMode#DiaryMode3 > > It's not working, since the mail sent by the script doesn't contain > all of the entries of my diary file. It contains almost only > automatical entries like holidays. A few personal entries are > included, however, about two out of 20. Does anybody have an idea > what's going wrong here? > > I add the script and my settings below. > > Thanks for help > Sven > > ------------ > > Here is the script (it's one line in the original; I tried 50 days > just to see if any entry is caught at all, it should be 7 or less > after I got it working): > > #!/bin/bash > emacs --batch --eval "(setq diary-mail-days 50 european-calendar-style > t diary-file \"~/aktuell/myconf/diary\" diary-mail-addr > \"sven.bretfeld@relwi.unibe.ch\")" -l diary-lib -f diary-mail-entries You are probably aware that --batch implies --no-init-file, which means your personal .emacs and installation's default.el files are not loaded. Rather than partially replicating the contents of those files with --eval etc., why not explicitly load them: emacs --batch --load ~/.emacs --load default.el --funcall diary-mail-entries > And here are the diary-settings of my .emacs: > > (setq diary-file "~/aktuell/myconf/diary") > > ;; Europäisch > (setq european-calendar-style 't) > (setq calendar-week-start-day 1 > calendar-day-name-array > ["Sonntag" "Montag" "Dienstag" "Mittwoch" > "Donnerstag" "Freitag" "Samstag"] > calendar-month-name-array > ["Januar" "Februar" "März" "April" "Mai" > "Juni" "Juli" "August" "September" > "Oktober" "November" "Dezember"]) > > ;; Start with diary (if there is an entry today) > (diary) > > ;; Timer > (display-time) > (add-hook 'diary-hook 'appt-make-list) > (diary 0) > > ;; LaTeX output des Kalenders > (setq cal-tex-diary 't) -- Kevin Rodgers Denver, Colorado, USA