Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: I broke my !$

On Oct 5,  7:41am, Jay Levitt wrote:
} After playing with zsh_add_history, or possibly at some time before
} then, I broke !$...
} % ls !$
} ls ls ~/.zsh_history

First check whether you broke history itself?  That is, if you recall
the command line with ctl-p or list it with the "history" command, is
the first word already doubled?  If so, it's probably something to do
with a zshaddhistory hook function.

Next check the value of $histchars -- I'm not sure how this would get
that specific result, but it's another way to break history. [*]

Nothing else comes to mind just now.  Selectively disabling parts of
your startup until you find a culprit as suggested by Daniel is the
most certain way to track it down.

[*] For example, if the first character of histchars is '$' then you
can't get the equivalent of !! any more, because in $$ the second $
is interpreted as a word designator "the last argument" instead of
as the event designator "the previous command".

Messages sorted by: Reverse Date, Date, Thread, Author