• m15otw@feddit.uk
    link
    fedilink
    English
    arrow-up
    1
    ·
    1 year ago

    Ctrl+R

    Then type any part of the command (filename, search string, etc)

    Ctrl+R again to cycle through the matches.

    (Best feature in bash)

  • tobier@lemmy.world
    link
    fedilink
    English
    arrow-up
    1
    ·
    1 year ago

    This is why I switched to fish; it seems to be much smarter understanding what I want to type.

    • amos@lemmy.world
      link
      fedilink
      English
      arrow-up
      1
      ·
      1 year ago

      Yeah it’s great how ctrl-r is kinda the default instead of something you have to go out of your way to use. Just start typing a command and the up arrow will only cycle through history that matches what you’ve typed so far.