From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Augusto Stoffel Newsgroups: gmane.emacs.devel Subject: Re: Buffer-local process environments Date: Fri, 30 Apr 2021 09:00:30 +0200 Message-ID: <87fsz8cl4h.fsf@gmail.com> References: <87eeets6jf.fsf@gmail.com> <8735v9yudx.fsf@gmx.de> <87y2d180a8.fsf@gmail.com> <87tunpx9xw.fsf@gmx.de> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="29053"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) Cc: emacs-devel@gnu.org To: Michael Albinus Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Apr 30 09:06:45 2021 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lcNEZ-0007Ra-NZ for ged-emacs-devel@m.gmane-mx.org; Fri, 30 Apr 2021 09:06:43 +0200 Original-Received: from localhost ([::1]:47554 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lcNEY-0002r8-Q3 for ged-emacs-devel@m.gmane-mx.org; Fri, 30 Apr 2021 03:06:42 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:49992) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lcN8i-0005RM-Eq for emacs-devel@gnu.org; Fri, 30 Apr 2021 03:00:44 -0400 Original-Received: from mail-ej1-x629.google.com ([2a00:1450:4864:20::629]:46835) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lcN8f-0001fY-1b for emacs-devel@gnu.org; Fri, 30 Apr 2021 03:00:40 -0400 Original-Received: by mail-ej1-x629.google.com with SMTP id u21so103697624ejo.13 for ; Fri, 30 Apr 2021 00:00:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=wWHRyU2KXWPVblCGpMo/y0+LkknMjfOVNsiOF4/bW64=; b=CyAB2wXbLjG4G7pox9XS29/HGXcMvMQTSB6zOheTr08ammqGeTAmxYoUHi/mAlk354 dge3P5lUSKae/cCietYjTWPmdJyiTi66MqLTNsJ6ENzLrUqznj24UgCac/nlAR1+7X43 pstUeNPkmtLiJTaQsJXtJyBegPOorlF+8cGI6ufgjyLoMeVASCnsyDIsHu6vjj3DwheN 6Y439xPaWQEa51bdfGstlYpcAQJFcf4MhS9nO8cCG5GTBBNmesGrKhhGWDZWg/rMGcgO YMDbaTwl98bvrOq9+zw/630rggrdeAJ1EKwbx4nqWMHv/M4RpYvDGL+i4TQHGsiOSA8d gJpA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=wWHRyU2KXWPVblCGpMo/y0+LkknMjfOVNsiOF4/bW64=; b=IehlV4+uqf0kAej9eK33F35S6qQqpy1fmRddUUNmJV8rn7vbKnqKYFTS3bE3tAXOQW rWG44r9qCNkkUVBGH3OtfclvpFAdSTZBkxhfpeGkTZMDpM9C1rd6DbwWJJb8V9VM6bq2 6w6lthKIJl8046at+2W5DZE6/hlozYptraKgWo81tUnNdhYeAtFJp0aZa/P1VyR67KuT 8hA9OsY2Dwx6mRYkAh3ENAgQ6jJ73Vd8xA4WYP9HrjGlXNo8UDOerRN14bjo1dfbucyD oWK9BhUZ37RvlXUpYak8UCuTVd4ChmUCI2sZn+uqc4CXUkslkpjC6jtyUUDx9lq54P8F 6lDQ== X-Gm-Message-State: AOAM532AhrRMb65IfkVl3VoR6jkMhP0k5Yl6jyJlovNTzEhpyLjcxppr 4+HBAPnTe1swyM2BBpKjZshNh3xzuTYexA== X-Google-Smtp-Source: ABdhPJx1QMOvPv3hwzzpgFHmAHjHXCgizbVwyLTJeE5fJTIPQ974U8YjBVE00JcKm1YIg9nS7jCTKw== X-Received: by 2002:a17:906:a403:: with SMTP id l3mr2672381ejz.251.1619766032130; Fri, 30 Apr 2021 00:00:32 -0700 (PDT) Original-Received: from ars3 ([2a02:908:2211:8540::68a]) by smtp.gmail.com with ESMTPSA id ch30sm567933edb.92.2021.04.30.00.00.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 30 Apr 2021 00:00:31 -0700 (PDT) In-Reply-To: <87tunpx9xw.fsf@gmx.de> (Michael Albinus's message of "Thu, 29 Apr 2021 19:44:11 +0200") Received-SPF: pass client-ip=2a00:1450:4864:20::629; envelope-from=arstoffel@gmail.com; helo=mail-ej1-x629.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 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-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:268653 Archived-At: Hi again, >> But I think it's a Tramp bug. Tramp is supposed to completely ignore >> `process-environment', right? So it shouldn't matter if that variable >> is buffer local or not. > > No. See my reply the other message. The following prints the words "dangerous" on emacs -Q. Also if I replace "/sudo::/" by any of the ssh hosts I have access to. This isn't expected, is it? (let ((default-directory "/sudo::/")) (setq-local process-environment (cons (concat "PATH=/dangerous:" (getenv "PATH")) process-environment)) (shell-command "echo $PATH" t)) >> True. "Connection-local variable" sounds a lot like "project-local >> variable" to me. Maybe there could be a unified mechanism. > > No, they are not project-local. For example, via connection-local > variables you could specify which shell to use on remote. I was just saying there's perhaps an analogy here. "Project-local variables" isn't a thing, as far as I know, but perhaps something like that could be introduced. I'm not trying to make a concrete suggestion right now. :-)