Not sure if this will help or not. If you type 'vim' the command you use most that start with vim is offered (greyed out), you can press ctrl+f to complete it and enter to run it, if instead you press up or ctrl+p the most recent command starting with 'vim' is completed, pressing up/ctrl+p again will complete the second most recent command etc etc.

I think there's also a way to scroll through the most common commands (greyed out) but I don't know how to do that.

On 11/12/2015 15:51, Michael Jones wrote:
Thanks for the response. If I press shift + tab then I get a kind of search dialogue (which looks great!) for various possible commands but related to what's on the system rather than what is in my history. I am sorry if wasn't clear, I was hoping to learn how to navigate my command history in a manner which feels consistent whether I'm going for the last command I ran or one before that.

My issue at the moment is that it feels like it is a different key to get to & run the last command versus getting to & running the second to last command.

Thanks again,
Michael

On 8 December 2015 at 23:14, Jônatas Davi Paganini <jonata...@gmail.com <mailto:jonata...@gmail.com>> wrote:

    Hi Michael! Have you tried shift + tab then tab again?

    On Tue, Dec 8, 2015 at 7:47 PM, Michael Jones
    <m.pricejo...@gmail.com <mailto:m.pricejo...@gmail.com>> wrote:

        Hi,

        I'm new to fish shell and generally loving it. A great
        experience so far.

        I have one behaviour I'd like to continue from my zsh setup
        which is searching the history. On zsh, if I type the start of
        a command like 'vim' then it doesn't suggest anything
        immediately but if I do a history-search-backward style key
        press then it completes to the last command I ran that started
        with 'vim' and I can press 'enter' to run it or repeat the
        history-search thingy to find the command before that, etc.

        So it is the same pattern for the last command or the one
        before it, just more key presses.

        With fish, if I type 'vim' then it ghosts in the last command
        I ran that starts with 'vim' and if I click
        history-search-backward thingy then I get the second to last
        command. So if I want to run the last command, I currently
        have to press 'right arrow' to complete the ghosting then
        enter and if I want the second to last then I have to press
        history-search-backward and then press enter. This small
        difference is throwing me off and I'd like to emulate the
        behaviour I had with zsh.

        Is that possible? I've had a little look at some of the fish
        scripts and the use of the 'commandline' command but I can't
        see how I would achieve the results I'm after. Any help would
        be much appreciated!

        Thanks,
        Michael

        
------------------------------------------------------------------------------

        _______________________________________________
        Fish-users mailing list
        Fish-users@lists.sourceforge.net
        <mailto:Fish-users@lists.sourceforge.net>
        https://lists.sourceforge.net/lists/listinfo/fish-users




-- atenciosamente,

    Jônatas Davi Paganini.
    --
    *ideia.me <http://ideia.me> *| *invent.to <http://invent.to/>*




------------------------------------------------------------------------------


_______________________________________________
Fish-users mailing list
Fish-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/fish-users

------------------------------------------------------------------------------
_______________________________________________
Fish-users mailing list
Fish-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/fish-users

Reply via email to