From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stefan Kangas Newsgroups: gmane.emacs.bugs Subject: bug#43735: 28.0.50; eshell: No such directory found via CDPATH environment variable Date: Wed, 10 Mar 2021 06:13:57 -0800 Message-ID: References: <86mu16tvqy.fsf@protected.rcdrun.com> <87sgaxq3ze.fsf@gnus.org> <83d021hn0z.fsf@gnu.org> <20201001191914.GM4797@protected.rcdrun.com> <87k0w921kt.fsf@gnus.org> <20201001192655.GP4797@protected.rcdrun.com> <87blhl201f.fsf@gnus.org> <87ft15mojb.fsf@gnus.org> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="35951"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 43735@debbugs.gnu.org, Jean Louis To: Lars Ingebrigtsen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Mar 10 15:15:13 2021 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1lJzcF-0009BT-M6 for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 10 Mar 2021 15:15:11 +0100 Original-Received: from localhost ([::1]:55062 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lJzcE-0006Ca-Nn for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 10 Mar 2021 09:15:10 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:60624) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lJzc6-00067I-5c for bug-gnu-emacs@gnu.org; Wed, 10 Mar 2021 09:15:02 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:37752) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lJzc5-0007pA-UH for bug-gnu-emacs@gnu.org; Wed, 10 Mar 2021 09:15:01 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1lJzc5-00067Z-QC for bug-gnu-emacs@gnu.org; Wed, 10 Mar 2021 09:15:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Kangas Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 10 Mar 2021 14:15:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 43735 X-GNU-PR-Package: emacs Original-Received: via spool by 43735-submit@debbugs.gnu.org id=B43735.161538564623453 (code B ref 43735); Wed, 10 Mar 2021 14:15:01 +0000 Original-Received: (at 43735) by debbugs.gnu.org; 10 Mar 2021 14:14:06 +0000 Original-Received: from localhost ([127.0.0.1]:49298 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lJzbB-00066C-M2 for submit@debbugs.gnu.org; Wed, 10 Mar 2021 09:14:05 -0500 Original-Received: from mail-pg1-f179.google.com ([209.85.215.179]:44246) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lJzbA-00065a-1H for 43735@debbugs.gnu.org; Wed, 10 Mar 2021 09:14:04 -0500 Original-Received: by mail-pg1-f179.google.com with SMTP id t37so686696pga.11 for <43735@debbugs.gnu.org>; Wed, 10 Mar 2021 06:14:04 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:in-reply-to:references:mime-version:date :message-id:subject:to:cc; bh=0371sEZidhhGtZZ+KPQxJnkxl7bJm5fRvAJr1BUJSk8=; b=krNv0kh7qjKlxevDgtNcuXaPCGT5K99bzefSSgkcLWalQlpE9vqu/WpzcE8+4ER+dU 6xPD6FUtbFnlYif/VobKdm2781tgzVP9cBRsKOPG5BtGb+OdSp4z4r/26p1nqAC/mpiA 7Wi/pAMQNbDbeYfSNmQbCnZMl/DnMq6pkFb4R6IHKWRJ1s7KB6t2QV25RYajvxAHrBKA GsjR1qfAj54lCOFQEJ4A75WcTTsmw9Q9k/OyvqXuLgSTuU46nqBsIT6Fla4ghY4/dCjF /VI+T+SEiyny6h9nQcNp+FBOMasW4gWuX4FNJJMd9rVxMk2+EOKCYhJe8mdJeJ6akgyv ef0w== X-Gm-Message-State: AOAM530SWgZOQnWTcuqfM5vej+TDAumXWYu3pHxbtzWglX3SAKZqcNVb BJUFrceHWzQ/JCbK7uUolOupT8mWBrDNinGKS5g= X-Google-Smtp-Source: ABdhPJzR9ojdiQ+OHO+gyCmJCRZA9Yp785rFoJYcbodTjO3J3+9v/oBWc9vGfBmR6ZrBFqEpG3C0fp4HzPwGxRCoRG4= X-Received: by 2002:a63:6206:: with SMTP id w6mr2923074pgb.363.1615385638378; Wed, 10 Mar 2021 06:13:58 -0800 (PST) Original-Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Wed, 10 Mar 2021 06:13:57 -0800 In-Reply-To: <87ft15mojb.fsf@gnus.org> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:201987 Archived-At: Lars Ingebrigtsen writes: > Stefan Kangas writes: > >> BTW, the error message here should really not be talking about CDPATH in >> this case, it is just confusing: >> >> Welcome to the Emacs shell >> >> ~/org/notes $ cd ~/wip/non-existent >> No such directory found via CDPATH environment variable >> ~/org/notes $ cd ~/wip/emacs >> ~/wip/emacs $ >> >> But (getenv "CDPATH") => nil > > Yes, I agree completely. I installed the following on master, but we still have to fix the bug in this report: diff --git a/lisp/files.el b/lisp/files.el index e5fa1d8b22..2868be77f2 100644 --- a/lisp/files.el +++ b/lisp/files.el @@ -823,7 +823,9 @@ cd (expand-file-name dir)) (locate-file dir cd-path nil (lambda (f) (and (file-directory-p f) 'dir-ok))) - (error "No such directory found via CDPATH environment variable")))) + (if (getenv "CDPATH") + (error "No such directory found via CDPATH environment variable: %s" dir) + (error "No such directory: %s" dir))))) (defun directory-files-recursively (dir regexp &optional include-directories predicate