GNU bug report logs - #27817
26.0.50; Dired: Support eshell/ls from the beginning if user want to

Previous Next

Package: emacs;

Reported by: Tino Calancha <tino.calancha <at> gmail.com>

Date: Tue, 25 Jul 2017 06:53:02 UTC

Severity: minor

Found in version 26.0.50

Done: Tino Calancha <tino.calancha <at> gmail.com>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 27817 in the body.
You can then email your comments to 27817 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#27817; Package emacs. (Tue, 25 Jul 2017 06:53:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Tino Calancha <tino.calancha <at> gmail.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Tue, 25 Jul 2017 06:53:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Tino Calancha <tino.calancha <at> gmail.com>
To: bug-gnu-emacs <at> gnu.org
Subject: 26.0.50; Dired: Support eshell/ls from the beginning if user want to
Date: Tue, 25 Jul 2017 15:52:29 +0900
An user must be able to use Dired with eshell/ls at the
beginning even if s?he doesn't have installed an external
"ls" program.

I) emacs -Q -l em-ls
M-: (progn
      (setq insert-directory-program "foobar-ls"
            eshell-ls-use-in-dired t)
      (dired source-directory)) RET

;; We got an error because `insert-directory-program' was called.
;; Now compare with ls-lisp; in this case `insert-directory-program'
;; is not called.
II) emacs -Q -l ls-lisp
M-: (progn
      (setq insert-directory-program "foobar-ls"
            ls-lisp-use-insert-directory-program nil)
      (dired source-directory)) RET

--8<-----------------------------cut here---------------start------------->8---
commit 6322f2932e9a083e01bb86aa219fc8256443c33f
Author: Tino Calancha <tino.calancha <at> gmail.com>
Date:   Tue Jul 25 15:46:54 2017 +0900

    Dired: Support eshell/ls from the beginning if user want to
    
    * lisp/dired.el (dired-insert-directory): Check for em-ls as well.
    * test/lisp/dired-tests.el (dired-test-bug27817): Add test.

diff --git a/lisp/dired.el b/lisp/dired.el
index 9d500a9f52..3b29c7129d 100644
--- a/lisp/dired.el
+++ b/lisp/dired.el
@@ -1207,6 +1207,7 @@ dired-insert-directory
 	 ;; as indicated by `ls-lisp-use-insert-directory-program'.
 	 (not (and (featurep 'ls-lisp)
 		   (null ls-lisp-use-insert-directory-program)))
+         (not (and (featurep 'eshell) (bound-and-true-p eshell-ls-use-in-dired)))
 	 (or (if (eq dired-use-ls-dired 'unspecified)
 		 ;; Check whether "ls --dired" gives exit code 0, and
 		 ;; save the answer in `dired-use-ls-dired'.
diff --git a/test/lisp/dired-tests.el b/test/lisp/dired-tests.el
index 69331457c0..601d65768b 100644
--- a/test/lisp/dired-tests.el
+++ b/test/lisp/dired-tests.el
@@ -175,5 +175,18 @@
           (should (looking-at "src")))
       (when (buffer-live-p buf) (kill-buffer buf)))))
 
+(ert-deftest dired-test-bug27817 ()
+  "Test for http://debbugs.gnu.org/27817 ."
+  (require 'em-ls)
+  (let ((orig eshell-ls-use-in-dired)
+        (dired-use-ls-dired 'unspecified)
+        buf insert-directory-program)
+    (unwind-protect
+        (progn
+          (customize-set-variable 'eshell-ls-use-in-dired t)
+          (should (setq buf (dired source-directory))))
+      (customize-set-variable 'eshell-ls-use-in-dired orig)
+      (and (buffer-live-p buf) (kill-buffer)))))
+
 (provide 'dired-tests)
 ;; dired-tests.el ends here

--8<-----------------------------cut here---------------end--------------->8---
In GNU Emacs 26.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.22.11)
 of 2017-07-25
Repository revision: 565cfd9f6c19e4d2aa318efdf19bdc56175bd153




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#27817; Package emacs. (Tue, 25 Jul 2017 07:02:02 GMT) Full text and rfc822 format available.

Message #8 received at 27817 <at> debbugs.gnu.org (full text, mbox):

From: Tino Calancha <tino.calancha <at> gmail.com>
To: 27817 <at> debbugs.gnu.org
Subject: Re: bug#27817: 26.0.50;
 Dired: Support eshell/ls from the beginning if user want to
Date: Tue, 25 Jul 2017 16:00:59 +0900
Tino Calancha <tino.calancha <at> gmail.com> writes:

> An user must be able to use Dired with eshell/ls at the
> beginning even if s?he doesn't have installed an external
> "ls" program.
>
> I) emacs -Q -l em-ls
> M-: (progn
>       (setq insert-directory-program "foobar-ls"
>             eshell-ls-use-in-dired t)
>       (dired source-directory)) RET
;; Sorry, previous form should be as follows (in order to
;; `insert-directory' get the advice):
M-x: (progn
       (setq insert-directory-program "foobar-ls")
       (customize-set-variable 'eshell-ls-use-in-dired t)
       (dired source-directory))




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#27817; Package emacs. (Tue, 25 Jul 2017 14:34:02 GMT) Full text and rfc822 format available.

Message #11 received at 27817 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Tino Calancha <tino.calancha <at> gmail.com>
Cc: 27817 <at> debbugs.gnu.org
Subject: Re: bug#27817: 26.0.50;
 Dired: Support eshell/ls from the beginning if user want to
Date: Tue, 25 Jul 2017 17:33:48 +0300
> From: Tino Calancha <tino.calancha <at> gmail.com>
> Date: Tue, 25 Jul 2017 15:52:29 +0900
> 
> commit 6322f2932e9a083e01bb86aa219fc8256443c33f
> Author: Tino Calancha <tino.calancha <at> gmail.com>
> Date:   Tue Jul 25 15:46:54 2017 +0900
> 
>     Dired: Support eshell/ls from the beginning if user want to
>     
>     * lisp/dired.el (dired-insert-directory): Check for em-ls as well.
>     * test/lisp/dired-tests.el (dired-test-bug27817): Add test.

Looks okay, but (a) please cite the bug number in the commit log
message, and (b) shouldn't this:

> +         (not (and (featurep 'eshell) (bound-and-true-p eshell-ls-use-in-dired)))
                                                           ^^^^^^^^^^^^^^^^^^^^^^

quote eshell-ls-use-in-dired?

Thanks.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#27817; Package emacs. (Tue, 25 Jul 2017 14:40:01 GMT) Full text and rfc822 format available.

Message #14 received at 27817 <at> debbugs.gnu.org (full text, mbox):

From: Tino Calancha <tino.calancha <at> gmail.com>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 27817 <at> debbugs.gnu.org
Subject: Re: bug#27817: 26.0.50; Dired: Support eshell/ls from the beginning
 if user want to
Date: Tue, 25 Jul 2017 23:38:56 +0900 (JST)

On Tue, 25 Jul 2017, Eli Zaretskii wrote:

>> From: Tino Calancha <tino.calancha <at> gmail.com>
>> Date: Tue, 25 Jul 2017 15:52:29 +0900
>>
>> commit 6322f2932e9a083e01bb86aa219fc8256443c33f
>> Author: Tino Calancha <tino.calancha <at> gmail.com>
>> Date:   Tue Jul 25 15:46:54 2017 +0900
>>
>>     Dired: Support eshell/ls from the beginning if user want to
>>
>>     * lisp/dired.el (dired-insert-directory): Check for em-ls as well.
>>     * test/lisp/dired-tests.el (dired-test-bug27817): Add test.
>
> Looks okay, but (a) please cite the bug number in the commit log
> message, and (b) shouldn't this:
Thank you.  i will do.
>
>> +         (not (and (featurep 'eshell) (bound-and-true-p eshell-ls-use-in-dired)))
> quote eshell-ls-use-in-dired?
I don't think so.  But i drank 2 beer so i migh be wrong...




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#27817; Package emacs. (Tue, 25 Jul 2017 14:49:01 GMT) Full text and rfc822 format available.

Message #17 received at 27817 <at> debbugs.gnu.org (full text, mbox):

From: Noam Postavsky <npostavs <at> users.sourceforge.net>
To: Tino Calancha <tino.calancha <at> gmail.com>
Cc: 27817 <at> debbugs.gnu.org, Eli Zaretskii <eliz <at> gnu.org>
Subject: Re: bug#27817: 26.0.50; Dired: Support eshell/ls from the beginning
 if user want to
Date: Tue, 25 Jul 2017 10:48:24 -0400
On Tue, Jul 25, 2017 at 10:38 AM, Tino Calancha <tino.calancha <at> gmail.com> wrote:
>>
>>
>>> +         (not (and (featurep 'eshell) (bound-and-true-p
>>> eshell-ls-use-in-dired)))
>>
>> quote eshell-ls-use-in-dired?
>
> I don't think so.  But i drank 2 beer so i migh be wrong...

bound-and-true-p is a macro, its argument doesn't need quoting. boundp
is a function, its argument does need quoting. Trips me up too.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#27817; Package emacs. (Tue, 25 Jul 2017 14:49:01 GMT) Full text and rfc822 format available.

Message #20 received at 27817 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Tino Calancha <tino.calancha <at> gmail.com>
Cc: 27817 <at> debbugs.gnu.org
Subject: Re: bug#27817: 26.0.50; Dired: Support eshell/ls from the beginning
 if user want to
Date: Tue, 25 Jul 2017 17:48:25 +0300
> From: Tino Calancha <tino.calancha <at> gmail.com>
> Date: Tue, 25 Jul 2017 23:38:56 +0900 (JST)
> cc: 27817 <at> debbugs.gnu.org
> 
> >> +         (not (and (featurep 'eshell) (bound-and-true-p eshell-ls-use-in-dired)))
> > quote eshell-ls-use-in-dired?
> I don't think so.  But i drank 2 beer so i migh be wrong...

Ah, I see bound-and-true-p confusingly deviates from boundp by quoting
its argument.  So much for mnemonic value...

Sorry.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#27817; Package emacs. (Tue, 25 Jul 2017 15:03:02 GMT) Full text and rfc822 format available.

Message #23 received at 27817 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Noam Postavsky <npostavs <at> users.sourceforge.net>
Cc: 27817 <at> debbugs.gnu.org, tino.calancha <at> gmail.com
Subject: Re: bug#27817: 26.0.50; Dired: Support eshell/ls from the beginning
 if user want to
Date: Tue, 25 Jul 2017 18:02:44 +0300
> From: Noam Postavsky <npostavs <at> users.sourceforge.net>
> Date: Tue, 25 Jul 2017 10:48:24 -0400
> Cc: Eli Zaretskii <eliz <at> gnu.org>, 27817 <at> debbugs.gnu.org
> 
> Trips me up too.

Then I'm in good company ;-)




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#27817; Package emacs. (Tue, 25 Jul 2017 15:10:01 GMT) Full text and rfc822 format available.

Message #26 received at 27817 <at> debbugs.gnu.org (full text, mbox):

From: Tino Calancha <tino.calancha <at> gmail.com>
To: Noam Postavsky <npostavs <at> users.sourceforge.net>
Cc: 27817 <at> debbugs.gnu.org
Subject: Re: bug#27817: 26.0.50; Dired: Support eshell/ls from the beginning
 if user want to
Date: Wed, 26 Jul 2017 00:09:31 +0900 (JST)

On Tue, 25 Jul 2017, Noam Postavsky wrote:

> On Tue, Jul 25, 2017 at 10:38 AM, Tino Calancha <tino.calancha <at> gmail.com> wrote:
>>>
>>>
>>>> +         (not (and (featurep 'eshell) (bound-and-true-p
>>>> eshell-ls-use-in-dired)))
>>>
>>> quote eshell-ls-use-in-dired?
>>
>> I don't think so.  But i drank 2 beer so i migh be wrong...
>
> bound-and-true-p is a macro, its argument doesn't need quoting. boundp
> is a function, its argument does need quoting. Trips me up too.
Thank you for the support! I understand you until the second period.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#27817; Package emacs. (Tue, 25 Jul 2017 15:29:02 GMT) Full text and rfc822 format available.

Message #29 received at 27817 <at> debbugs.gnu.org (full text, mbox):

From: Noam Postavsky <npostavs <at> users.sourceforge.net>
To: Tino Calancha <tino.calancha <at> gmail.com>
Cc: 27817 <at> debbugs.gnu.org
Subject: Re: bug#27817: 26.0.50; Dired: Support eshell/ls from the beginning
 if user want to
Date: Tue, 25 Jul 2017 11:27:53 -0400
On Tue, Jul 25, 2017 at 11:09 AM, Tino Calancha <tino.calancha <at> gmail.com> wrote:
>> bound-and-true-p is a macro, its argument doesn't need quoting. boundp
>> is a function, its argument does need quoting. Trips me up too.
>
> Thank you for the support! I understand you until the second period.

Oh, I just meant that I also often get the quoting for
boundp/bound-and-true-p wrong.

https://en.wiktionary.org/wiki/trip_up

    trip up: 2. (transitive) To cause (someone) to commit an error,
trick into a mistake.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#27817; Package emacs. (Tue, 25 Jul 2017 15:35:01 GMT) Full text and rfc822 format available.

Message #32 received at 27817 <at> debbugs.gnu.org (full text, mbox):

From: Tino Calancha <tino.calancha <at> gmail.com>
To: Noam Postavsky <npostavs <at> users.sourceforge.net>
Cc: 27817 <at> debbugs.gnu.org
Subject: Re: bug#27817: 26.0.50; Dired: Support eshell/ls from the beginning
 if user want to
Date: Wed, 26 Jul 2017 00:34:43 +0900 (JST)
[Message part 1 (text/plain, inline)]

On Tue, 25 Jul 2017, Noam Postavsky wrote:

> https://en.wiktionary.org/wiki/trip_up
>
>    trip up: 2. (transitive) To cause (someone) to commit an error,
> trick into a mistake.
google.translate (from english to spanish):
"Trips me up too" ===> "Me dispara tambiƩn"
I read the second as: "It shoots me too".

Reply sent to Tino Calancha <tino.calancha <at> gmail.com>:
You have taken responsibility. (Wed, 26 Jul 2017 07:58:01 GMT) Full text and rfc822 format available.

Notification sent to Tino Calancha <tino.calancha <at> gmail.com>:
bug acknowledged by developer. (Wed, 26 Jul 2017 07:58:02 GMT) Full text and rfc822 format available.

Message #37 received at 27817-done <at> debbugs.gnu.org (full text, mbox):

From: Tino Calancha <tino.calancha <at> gmail.com>
To: 27817-done <at> debbugs.gnu.org
Subject: Re: bug#27817: 26.0.50;
 Dired: Support eshell/ls from the beginning if user want to
Date: Wed, 26 Jul 2017 16:57:46 +0900
Eli Zaretskii <eliz <at> gnu.org> writes:

>>     Dired: Support eshell/ls from the beginning if user want to
> Looks okay
Fixed in master branch as commit d5c41e99a2071e3ee491a53a0f9506f62fa6ae54




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Wed, 23 Aug 2017 11:24:04 GMT) Full text and rfc822 format available.

This bug report was last modified 6 years and 238 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.