[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: fc -l history specification out of range with empty history
From: |
Grisha Levit |
Subject: |
Re: fc -l history specification out of range with empty history |
Date: |
Tue, 21 Mar 2017 15:09:38 -0400 |
On Tue, Mar 21, 2017 at 11:59 AM, Chet Ramey <chet.ramey@case.edu> wrote:
>> As a special case, `fc -l -0' usually prints itself but not in the
>> empty history (or HISTSIZE=1) case.
>
> Yeah, that's a special case, but not when there are no commands in
> the history list.
Thanks for the explanation. FWIW my less-degenerate use case was
getting the just-entered command in PS0 but `history 1' should
probably do just as well in this case.