From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: PJ Weisberg Newsgroups: gmane.emacs.help Subject: Re: window local var? Date: Tue, 7 Sep 2010 09:12:35 -0700 Message-ID: References: <1283772789-sup-3909@nixos> <1283799526-sup-6956@nixos> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1283881663 25558 80.91.229.12 (7 Sep 2010 17:47:43 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 7 Sep 2010 17:47:43 +0000 (UTC) To: help-gnu-emacs Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Sep 07 19:47:42 2010 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.69) (envelope-from ) id 1Ot2Gk-0000jj-2U for geh-help-gnu-emacs@m.gmane.org; Tue, 07 Sep 2010 19:47:42 +0200 Original-Received: from [127.0.0.1] (port=34002 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Ot1np-0006ow-OX for geh-help-gnu-emacs@m.gmane.org; Tue, 07 Sep 2010 13:17:49 -0400 Original-Received: from [140.186.70.92] (port=50320 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Ot1Vt-0005PJ-RP for help-gnu-emacs@gnu.org; Tue, 07 Sep 2010 12:59:20 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1Ot12n-0002f4-Hx for help-gnu-emacs@gnu.org; Tue, 07 Sep 2010 12:29:14 -0400 Original-Received: from smtpauth11.prod.mesa1.secureserver.net ([64.202.165.33]:38704) by eggs.gnu.org with smtp (Exim 4.69) (envelope-from ) id 1Ot12n-0002ej-8v for help-gnu-emacs@gnu.org; Tue, 07 Sep 2010 12:29:13 -0400 Original-Received: (qmail 20693 invoked from network); 7 Sep 2010 16:29:10 -0000 Original-Received: from unknown (209.85.215.169) by smtpauth11.prod.mesa1.secureserver.net (64.202.165.33) with ESMTP; 07 Sep 2010 16:29:09 -0000 Original-Received: by eyh5 with SMTP id 5so2900956eyh.0 for ; Tue, 07 Sep 2010 09:29:07 -0700 (PDT) Original-Received: by 10.213.104.203 with SMTP id q11mr91282ebo.12.1283875956116; Tue, 07 Sep 2010 09:12:36 -0700 (PDT) Original-Received: by 10.213.7.17 with HTTP; Tue, 7 Sep 2010 09:12:35 -0700 (PDT) In-Reply-To: X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4-2.6 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:74915 Archived-At: On Mon, Sep 6, 2010 at 5:34 PM, PJ Weisberg w= rote: > (let ((env (frame-parameter (selected-frame) 'environment)) > =A0 =A0 =A0(current nil) > =A0 =A0 =A0(dir nil)) > =A0(while (and (not dir) t) > =A0 =A0(setq current (pop env)) > =A0 =A0(if (string-equal "PWD=3D" (subseq current 0 4)) > =A0 =A0 =A0 =A0(setq dir (subseq current 4)))) > =A0dir) Um, that "t" in the conditional was supposed to be "env". I wanted to see what error I would get if I let it fall off the end of the list without finding anything, and I forgot to put the check back in before I pasted it into the mail. :-/