From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id sG1vJ5GaB2K21wAAgWs5BA (envelope-from ) for ; Sat, 12 Feb 2022 12:31:29 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp10.migadu.com with LMTPS id AGYpIJGaB2J2hQEAG6o9tA (envelope-from ) for ; Sat, 12 Feb 2022 12:31:29 +0100 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 52260FC43 for ; Sat, 12 Feb 2022 12:31:29 +0100 (CET) Received: from localhost ([::1]:39088 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nIqci-0005KH-Av for larch@yhetil.org; Sat, 12 Feb 2022 06:31:28 -0500 Received: from eggs.gnu.org ([209.51.188.92]:60954) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nIqbY-0005K5-Dh for guix-devel@gnu.org; Sat, 12 Feb 2022 06:30:16 -0500 Received: from jpoiret.xyz ([206.189.101.64]:38852) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nIqbW-0004pd-RV for guix-devel@gnu.org; Sat, 12 Feb 2022 06:30:16 -0500 Received: from authenticated-user (jpoiret.xyz [206.189.101.64]) by jpoiret.xyz (Postfix) with ESMTPA id 18384184F2D; Sat, 12 Feb 2022 11:30:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=jpoiret.xyz; s=dkim; t=1644665412; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=TADykQ7kpNjapFri+CBaaY/1shNx6AIjF+gX2nx4u1g=; b=nFfUmXS1sVOEF58Amg1g0G2nwU+kM+/ygjtCHu7AFpOQn+i6jml6uVeJ/YuF2qMjNqIUWk UABo4W3IWNPJeCjIgxApjixfZ3O9AoAmghhTa+EBhfA8EInc53r+oYS8k/dBmpS55oY+2y bquhg3K4PLs5z1cp1vDsASMxXLK7w78O/1aXPKUe/CG0cES9bHHe6xH5Dj3LjChfnkKwSZ UihaagDx+6Kr5df67QK5u5pkQIFbf8FeUJHl8Hi+tbz9fI9r1x5gYk8mDAmRVFDavXq+KM NeoRoDKaSJb1WgT5Dj3aFkJmdA2sQ8cEFOzRIBzY4oxwAuC4v9JHagAje/0WnA== From: Josselin Poiret To: Mikhail Kryshen , Antonio Carlos Padoan Junior , guix-devel@gnu.org Subject: Re: emacs tramp in remote guix In-Reply-To: <87v8xkdcw7.fsf@kryshen.net> References: <87h795s97x.fsf.ref@yahoo.com.br> <87h795s97x.fsf@yahoo.com.br> <87v8xkdcw7.fsf@kryshen.net> Date: Sat, 12 Feb 2022 12:30:11 +0100 Message-ID: <87czjsmif0.fsf@jpoiret.xyz> MIME-Version: 1.0 Content-Type: text/plain X-Spamd-Bar: / Received-SPF: pass client-ip=206.189.101.64; envelope-from=dev@jpoiret.xyz; helo=jpoiret.xyz X-Spam_score_int: 2 X-Spam_score: 0.2 X-Spam_bar: / X-Spam_report: (0.2 / 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, FROM_SUSPICIOUS_NTLD=0.498, PDS_OTHER_BAD_TLD=1.769, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: guix-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+larch=yhetil.org@gnu.org Sender: "Guix-devel" X-Migadu-Flow: FLOW_IN X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1644665489; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=TADykQ7kpNjapFri+CBaaY/1shNx6AIjF+gX2nx4u1g=; b=qFMH8U+cSMpPVoIcLMPfCFZQwejg00f/PTqHCk6/hb/JYJOIJ48iWl1fY30FhVEAQd8fGy yzbATCuq7MfyJtV6QNrvbt3B/L/nm5l2jWvvN2ET4Rg6b224AICkxb2SzL+0Xf+morW+Kw hri9/HiEmZHK77pRvuzLYRjFERsTHPGH4Sf5maPQ9CL4ad5gfeltGVR4cGjhvunF0Sd9Qo 2MaDnh27mBP+we+XhZmNtTbgH2eT0/5MwnIjwOqH9aq5iYIUtJTM3Ya5YJPmYvRP3XBXG4 BsR7qjqWD+urpCvwzjiRVZbZLAGYpIB53B/9NWonNYbevVp5eRORpK3REjEsnQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1644665489; a=rsa-sha256; cv=none; b=OUXyKhZMyYg6BWYxEZGLmaqoc4763rD+v5dnV9Fp9UQeQnN8Lr9D9m73jg0w8d8C+Sz+gr zMpJ7Uig8T22ZuEFt+ZCkmwOqb07rSmkUOLXpgmx4xhHkILA43i5GLTQsYwsyUsm5palw9 yOIDSfVOibAnThB9uoWaNJ4obB5bYPia9ndkrgPYRZAUmUXYuN9+sdApGzUaCbYD+vCvfX 3WapS+9yKnq7O7KTuLPcDdkInAl6UCKHStmThzVojCMZNI5TqD97/oU7I3RlND8A/SOZ81 bxYG5G6R6DCKgyAuUk4WIs8m9VSCCaJ8HpSWqKm8bZTp8m1Ej5pkgMV9Ur7TOQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=jpoiret.xyz header.s=dkim header.b=nFfUmXS1; dmarc=pass (policy=reject) header.from=jpoiret.xyz; spf=pass (aspmx1.migadu.com: domain of "guix-devel-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-devel-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: -4.33 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=jpoiret.xyz header.s=dkim header.b=nFfUmXS1; dmarc=pass (policy=reject) header.from=jpoiret.xyz; spf=pass (aspmx1.migadu.com: domain of "guix-devel-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-devel-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: 52260FC43 X-Spam-Score: -4.33 X-Migadu-Scanner: scn0.migadu.com X-TUID: lSKIxUa4ZLkd Hello everyone, Mikhail Kryshen writes: > Hello, > > Antonio Carlos Padoan Junior writes: > >> Hello everybody, >> >> I'm trying to use emacs tramp to connect to a guix machine but tramp >> complains it can't find an appropriate 'ls' command. >> >> I tried to help tramp setting the following: >> (add-to-list 'tramp-remote-path "/run/current-system/profile/bin") > > For me this works. > >> But I'm still not lucky. I always get the same error. Is there any >> elegant way to correctly use tramp with a remote guix machine? > > You may need to delete ~/.emacs.d/tramp before starting Emacs for the > setting to take effect. I personally use --8<---------------cut here---------------start------------->8--- (require 'tramp) (connection-local-set-profile-variables 'guix-system '((tramp-remote-path . (tramp-own-remote-path)))) (connection-local-set-profiles '(:application tramp :protocol "sudo" :machine "hostname") 'guix-system) --8<---------------cut here---------------end--------------->8--- for tramp on my own machine. The symbol 'tramp-own-remote-path uses the login shell of the target to determine the environment to use, so is well suited for guix. You may need to adjust the :protocol and :machine keys of the connection-local-set-profiles call for your use case though. Best, -- Josselin Poiret