top | item 46564299

(no title)

mirzap | 1 month ago

I tried using Starship, and it’s clearly faster than Oh My Zsh, but my issue was that I relied on some useful Oh My Zsh features that I didn’t know how to replicate in Starship. One of these is history filtering - for example, when I type source and press the up arrow, I only see previously run source commands, which makes it easy to find what I’m looking for. I tried to get this working in Starship, but had no luck.

discuss

order

wolletd|1 month ago

I haven't checked out starship yet, but if I understand what you are using, that is Zle functionality. It's part of OMZs configuration (here: https://github.com/ohmyzsh/ohmyzsh/blob/master/lib/key-bindi...) but doesn't use other OMZ features.

I don't know if starship is still using Zle. If so, this should be possible to configure without OMZ.

mirzap|1 month ago

Oh thank you, I was looking for this. Will try it.

seanhunter|1 month ago

Control r. This is a zsh feature not a starship/oh my zsh feature

RHSeeger|1 month ago

I think that's just a standard readline functionality. It's available on bash, out of the box.

mirzap|1 month ago

Oh my god! How did I not know about this! Thank you! Are there any other useful tips like this one?

cromka|1 month ago

Ob Linux it's actually handled by inputrc

vladvasiliu|1 month ago

mirzap was probably using some omz plugin to do that, so if starship fully replaced omz, that functionality went away, too.

coaksford|1 month ago

I have never used Oh My Zsh, but I use Atuin to do this and it works excellently at that. You can even make it filter by what folder you're in and whether you want to search only this session or host (you can sync shell history across hosts). It never occurred to me that this is something I'd want from a shell prompt, which is what Starship is.

dagi3d|1 month ago

check atuin for history search