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

trivial problem with histverify

I have this command bound to PgUp:

     history 1 | grep --color=auto "[[:digit:]]  !!"

... it does the obvious thing, I type a string I want to search for in history and get a nice colored listing. When recalling a command from history with '!', I like to have 'setopt histverify' in case I want to edit the command, or just be sure I'm going to execute the correct command before it fires. However, if that option is set, it fouls up the above keybinding in the predictable way, it demands ENTER before it will work. It seems on the face of it that 'histverify' is not being very
smart about that, because the key binding isn't executing a command, it's
just making a listing. It seems as if the test for 'histverify' is just seeing the literal bangs in the key binding and not figuring out that there is really no command being executed. Is this really what we want? If so, is there a simple work-around? As it is, I just leave 'histverify' off, and try to be careful, so it's hardly important,
but I would  like to have it both ways if possible.

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