From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: Managing environments (Python venv, guix environment, etc.) Date: Fri, 15 Jul 2016 12:26:59 -0400 Message-ID: References: <87y453sy0n.fsf@earth.catern.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1468600117 6662 80.91.229.3 (15 Jul 2016 16:28:37 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 15 Jul 2016 16:28:37 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Jul 15 18:28:28 2016 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1bO5yM-0002ki-EC for ged-emacs-devel@m.gmane.org; Fri, 15 Jul 2016 18:28:18 +0200 Original-Received: from localhost ([::1]:33700 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bO5yL-0005cQ-Mr for ged-emacs-devel@m.gmane.org; Fri, 15 Jul 2016 12:28:17 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:54933) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bO5vN-0003ef-Cp for emacs-devel@gnu.org; Fri, 15 Jul 2016 12:25:14 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bO5vI-00038q-8Y for emacs-devel@gnu.org; Fri, 15 Jul 2016 12:25:12 -0400 Original-Received: from plane.gmane.org ([80.91.229.3]:48435) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bO5vI-00037f-0y for emacs-devel@gnu.org; Fri, 15 Jul 2016 12:25:08 -0400 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1bO5v8-0000DR-7S for emacs-devel@gnu.org; Fri, 15 Jul 2016 18:24:58 +0200 Original-Received: from 69-165-156-121.dsl.teksavvy.com ([69.165.156.121]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 15 Jul 2016 18:24:58 +0200 Original-Received: from monnier by 69-165-156-121.dsl.teksavvy.com with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 15 Jul 2016 18:24:58 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 30 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: 69-165-156-121.dsl.teksavvy.com User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1.50 (gnu/linux) Cancel-Lock: sha1:95zarrfsY3MrYAuDhh0a2KEHSc4= X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 80.91.229.3 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:205732 Archived-At: > - Make exec-path and process-environment buffer-local > I am told that this will cause a lot of bizarre behavior. In > particular, I understand that this won't work with M-x compile, which > reuses another buffer to run the compilation. Indeed, it probably won't work right. > - Make exec-path and process-environment a different kind of > buffer-local dynamic variable [...] > the buffer-locals of the buffer that was current at the time of the > M-x compile invocation. Too hand-wavy and the details are likely to be pretty ugly (lots of guessing involved). > - Use dir-locals > I'm not sure how this could work, given the problems with making > exec-path and process-environment buffer-local, but including it to be > complete. If M-x compile obeys dir-locals that could work, yes. Another option is to use process-file's file-name-handler-alist. And of course, yet another is to advice-add on call-process and start-process. Stefan