[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Proposal: ls-lisp.el handle --group-directories-first flag
From: |
Arthur Miller |
Subject: |
Re: Proposal: ls-lisp.el handle --group-directories-first flag |
Date: |
Fri, 16 Jul 2021 15:20:58 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) |
Eli Zaretskii <eliz@gnu.org> writes:
>> From: Arthur Miller <arthur.miller@live.com>
>> Date: Thu, 15 Jul 2021 11:19:52 +0200
>>
>> Just a minor 'out-of-the-box' quality of life improvement mostly for
>> MS Windows users. ls-lisp.el is default on MS Windows, and some users
>> might share their init configuration between their Gnu/Linux and MS
>> Windows systems, it might be nice to have ls-lisp.el recognize
>> `--group-directories-first' flag of Gnu ls program.
>>
>> I have just piggy-back on existing code here; I am not sure if I can
>> actually set `ls-lisp-dirs-firs' var to `t' when
>> `--group-directories-first' is found, so I am just converting this flag
>> to `y' so we can per-use existing machinery. But I would happily skip
>> `y' if it is acceptable to change users choice for `ls-lisp-dirs-first'
>> variable when `--group-directories-first' is present.
>
> This is not future-proof: what if 'ls' in some future release will
> have the -y option, and we'd want to support that in ls-lisp.el?
Yes, I knowm I just thought that world does not directly see an explosion of
'ls' applications development. Yes, I had an idea you wouldn't like the
hacky patch, it was nore of a joke.
> Doesn't it work to let-bind ls-lisp-dirs-first?
I don't know about that one. ls-lisp--insert-directory effectively
ensures that switches are passed further the line as a string of
chars. The flag is lost in the first step and can't be passed further
on. I am not sure it's worth the trouble to modify that behaviour. Or
maybe I don't know what you mean.
Anyway, see if this is acceptable. It adds one extra variable, so it's still
pretty cheap.
ls-lisp.patch
Description: Text Data
- Proposal: ls-lisp.el handle --group-directories-first flag, Arthur Miller, 2021/07/15
- Re: Proposal: ls-lisp.el handle --group-directories-first flag, Eli Zaretskii, 2021/07/16
- Re: Proposal: ls-lisp.el handle --group-directories-first flag,
Arthur Miller <=
- Re: Proposal: ls-lisp.el handle --group-directories-first flag, Eli Zaretskii, 2021/07/16
- Re: Proposal: ls-lisp.el handle --group-directories-first flag, Arthur Miller, 2021/07/16
- Re: Proposal: ls-lisp.el handle --group-directories-first flag, Eli Zaretskii, 2021/07/17
- Re: Proposal: ls-lisp.el handle --group-directories-first flag, Arthur Miller, 2021/07/19
- Re: Proposal: ls-lisp.el handle --group-directories-first flag, Eli Zaretskii, 2021/07/24
- Re: Proposal: ls-lisp.el handle --group-directories-first flag, Eli Zaretskii, 2021/07/24
- Re: Proposal: ls-lisp.el handle --group-directories-first flag, Arthur Miller, 2021/07/24
- Re: Proposal: ls-lisp.el handle --group-directories-first flag, Eli Zaretskii, 2021/07/24
- Re: Proposal: ls-lisp.el handle --group-directories-first flag, Arthur Miller, 2021/07/24
- Re: Proposal: ls-lisp.el handle --group-directories-first flag, Eli Zaretskii, 2021/07/24