From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Benjamin Riefenstahl Newsgroups: gmane.emacs.devel Subject: Re: carbon emacs on OS X 10.3 (Panther): how to fix environment? Date: Tue, 13 Jan 2004 12:16:52 +0100 Sender: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Message-ID: References: <6080F1A8-4516-11D8-9AA4-00039364573C@lafros.com> NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1073992779 26107 80.91.224.253 (13 Jan 2004 11:19:39 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 13 Jan 2004 11:19:39 +0000 (UTC) Cc: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Tue Jan 13 12:19:36 2004 Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1AgMa8-00014d-00 for ; Tue, 13 Jan 2004 12:19:36 +0100 Original-Received: from monty-python.gnu.org ([199.232.76.173]) by quimby.gnus.org with esmtp (Exim 3.35 #1 (Debian)) id 1AgMa7-0007mZ-00 for ; Tue, 13 Jan 2004 12:19:36 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.24) id 1AgMZz-00043y-5E for emacs-devel@quimby.gnus.org; Tue, 13 Jan 2004 06:19:27 -0500 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.24) id 1AgMZk-00041g-5O for emacs-devel@gnu.org; Tue, 13 Jan 2004 06:19:12 -0500 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.24) id 1AgMY4-0003RA-BF for emacs-devel@gnu.org; Tue, 13 Jan 2004 06:17:59 -0500 Original-Received: from [193.28.100.166] (helo=mail.epost.de) by monty-python.gnu.org with esmtp (Exim 4.24) id 1AgMY3-0003Qf-Fh; Tue, 13 Jan 2004 06:17:27 -0500 Original-Received: from seneca.benny.turtle-trading.net.epost.de (193.99.153.30) by mail.epost.de (6.7.015) id 400163060004839E; Tue, 13 Jan 2004 12:17:26 +0100 Original-To: John Wiegley In-Reply-To: (John Wiegley's message of "Mon, 12 Jan 2004 13:17:18 -0800") User-Agent: Gnus/5.1001 (Gnus v5.10.1) Emacs/21.3.50 (gnu/linux) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.2 Precedence: list List-Id: Emacs development discussions. List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Xref: main.gmane.org gmane.emacs.devel:19158 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:19158 Hi John, John Wiegley writes: > (when (file-readable-p "~/.MacOSX/environment.plist") > (with-temp-buffer > (insert-file-contents "~/.MacOSX/environment.plist") > (let* ((dict (cdr (assoc "dict" (read-xml))))) > (while dict > (when (string= "key" (caar dict)) > (setenv (car (cdr (car dict))) > (car (cdr (cadr dict)))) > (message "Setting %s=%s" (car (cdr (car dict))) > (car (cdr (cadr dict))))) > (setq dict (cddr dict))))) > > (setq exec-path nil) > (dolist (path (nreverse (split-string (getenv "PATH") ":"))) > (add-to-list 'exec-path path))) ?? Why do you need this? My understanding is that ~/.MacOSX/environment.plist is read by the Finder and that the variables are inherited automatically by Emacs. The code should only have an effect, if you log in through SSH, where the Finder isn't in the loop. But for that situation you can set the variables in ~/.cshrc or ~/.bashrc or somewhere similar. What am I missing? benny