From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Dmitry Gutov Newsgroups: gmane.emacs.devel Subject: Re: Name of buffers created by project-shell Date: Mon, 15 Mar 2021 02:41:03 +0200 Message-ID: <80c15296-ebf7-3030-993f-ffb01051d570@yandex.ru> References: <87czwh9rv9.fsf@gmail.com> <87zgz526gx.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="3280"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.7.1 Cc: emacs-devel To: Matthias Meulien Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Mon Mar 15 01:43:15 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 1lLbKF-0000lV-Iz for ged-emacs-devel@m.gmane-mx.org; Mon, 15 Mar 2021 01:43:15 +0100 Original-Received: from localhost ([::1]:48428 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lLbKE-0004Nl-Jw for ged-emacs-devel@m.gmane-mx.org; Sun, 14 Mar 2021 20:43:14 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:54320) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lLbIG-0003hi-6N for emacs-devel@gnu.org; Sun, 14 Mar 2021 20:41:12 -0400 Original-Received: from mail-wm1-x32b.google.com ([2a00:1450:4864:20::32b]:38490) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lLbID-0001oN-7L for emacs-devel@gnu.org; Sun, 14 Mar 2021 20:41:11 -0400 Original-Received: by mail-wm1-x32b.google.com with SMTP id m20-20020a7bcb940000b029010cab7e5a9fso19242982wmi.3 for ; Sun, 14 Mar 2021 17:41:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=bLLk4UxIsG+o2QvfuDrAeYSD9QF1kfBzAbwGng6nRcw=; b=cEf6wvnwV3DVo2NJYkvzjih0b/VM6gq8GrTeBq5FfOUCjA271aAUyPyK1XUKIE6tW9 f2rrMs2PV4ZUiVMjXqnYTTH3255lDglKnjrDRAjV6WA0XhpSBO4ksX7c/Ch4081XpWfc xgzj+NDcE0P/uOqGNDBKC/A72mpjpwhidvsJCpLvdzQxOdFJSuygyF4IdAALs3vSZUjo nIfwBUp24HblM/Wxn5Di9fE+2aomN8w6ziAAWRm3KLD9zvAeMNOV8i3C4ue5U9javMNt BUKIp0QYlg+kfbijD7mGRnfjw2JI/2y4rdDusKl6E0+JqwY/QukOnOywc2fQmXVXeb7r SqYw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:subject:to:cc:references:from:message-id :date:user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=bLLk4UxIsG+o2QvfuDrAeYSD9QF1kfBzAbwGng6nRcw=; b=aKV6wJX93BhVze9splgZHSFbIaYIwuAgp3ryJAR4LIaHlBBHJYh656pKj8D9P0/Mg6 CtO3gqAY/Gzx9r7DPwsgEyeD4ILxPc8pC3zOnJZF65RkWVzQ+z9XMfErE6shE+v3CYQK fn2qyM/ga1ye29fBJwYTe1bAoYgKkOtb6U/GTxnj3OjxxqjNkOyqQOeQAWpr/DF8wk8x LqfPJFGaAdTcWd7S1yX52JFFVll65id4zcwE3XdMnj17ZbcZMoZFT+zDyB3A5QACxdwq /qpSUqt3eTXjiU82FPzyOV0jCyFTpB+OXKxEJqa/+Ndn07hj+4oYeOQZDqF9Pbh7sLW3 jvgQ== X-Gm-Message-State: AOAM531rNydiSXkKPxatp/Suf8YCsPF17B9MBUokx2NLND+6FQFzL5Yi LgnWdBBlrFbMMjQIjRQ5DddltszLjKo= X-Google-Smtp-Source: ABdhPJzEoW8gxIjOsxSO84zJ8DfIyVADNKJ+Kt21KKWQb/XlxZ1B6/cXrrP/K6lKWI0aTO8Xbb/R3w== X-Received: by 2002:a05:600c:2215:: with SMTP id z21mr23951555wml.86.1615768866690; Sun, 14 Mar 2021 17:41:06 -0700 (PDT) Original-Received: from [192.168.0.6] ([46.251.119.176]) by smtp.googlemail.com with ESMTPSA id v2sm33342861wmj.1.2021.03.14.17.41.05 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 14 Mar 2021 17:41:06 -0700 (PDT) In-Reply-To: <87zgz526gx.fsf@gmail.com> Content-Language: en-US Received-SPF: pass client-ip=2a00:1450:4864:20::32b; envelope-from=raaahh@gmail.com; helo=mail-wm1-x32b.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.249, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.249, NICE_REPLY_A=-0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no 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:266471 Archived-At: On 14.03.2021 15:46, Matthias Meulien wrote: >> Both shell and eshell buffers can change their default-directory, but >> we can track which project they belong to with a new variable. See the >> attached patch. > > Thanks! I am testing it. > > I am not an eshell user but I guess the patch should use the variable > `eshell-buffer-name' defined in eshell.el in place of the hardcoded > "*eshell*" string. Makes sense. > I think there's a problem even without using C-u: > > `project-shell' from a buffer whose associated project root path is > /src/project1 creates a buffer named *shell*. > > Then `project-shell' from a buffer whose associated project root path is > /src/project2 creates a buffer named *shell* (I am using the > default `post-forward-angle-brackets' for `uniquify-buffer-name-style'). > > But the uniquify rationalize mecanism doesn't rename the first buffer to > *shell* which happens to be the case for buffers visiting > files... Yup, that's another bug. It should also how up for vc-dir buffers too. To reiterate the choices at this point, we either implement special buffer-naming scheme in project and give up on consistency with project-vc and uniquify-buffer-name-style, or we try to fix both problems we have found in uniquify so far. In theory, the latter would be ideal, and uniquify has certainly been lacking in developer attention. But I have no idea how much work that entails. If you have time, help in that area would be very welcome. Otherwise I'll have to add it to my list.