News for hackers. Stuff that matters.
Re:Show HN: McFly, a smart Bash history search CLI in Rust w... by jaster on Tuesday December 04, 2018 @05:10AM (#18598051)
Additional tip: if you overshoot and miss the command you wanted by hitting ctrl+R too much times (as it happens sometime when looking for an older command), you can go forward with ctrl+S. [EDIT: As Hikikomori pointed (thanks!), I got my shortcuts mixed up, ctrl+S is the shortcut for zsh, and the equivalent for bash is ctrl+shift+R]

(ctrl+S and ctrl+R are based on emacs shortcuts, where ctrl+S is search and ctrl+R is reverse search)

Re:Show HN: McFly, a smart Bash history search CLI in Rust w... by 0db532a0 on Tuesday December 04, 2018 @06:53AM (#18598576)
Note that your terminal emulator needs to pass the ctrl+S through. ctrl+S won’t work by default in a lot of cases from personal experience.
Re:Show HN: McFly, a smart Bash history search CLI in Rust w... by Hikikomori on Tuesday December 04, 2018 @05:19AM (#18598090)
Doesn't work on GNU bash, version 3.2.57(1)-release (x86_64-apple-darwin18)

ctrl+shift+r works though.

Re:Show HN: McFly, a smart Bash history search CLI in Rust w... by jaster on Tuesday December 04, 2018 @06:06AM (#18598300)
Yep you're right, I got my shortcuts between bash and zsh mixed-up. I edited my post, thanks for the correction.

(Not sure why bash did not go the obvious route here, I guess they already had something on ctrl+S when they implemented forward search...)

EDIT: actually, you can activate ctrl+S for search-foward on bash by using `stty -ixon`. See more info about why here https://unix.stackexchange.com/questions/141422/searching-hi...

Re:Show HN: McFly, a smart Bash history search CLI in Rust w... by fnord123 on Tuesday December 04, 2018 @07:12AM (#18598670)
ctrl-s is usually for pausing the terminal (where ctrl-q resumes it).

https://en.wikipedia.org/wiki/Software_flow_control