i just do a command close to what i want but slightly wrong just so i can do thefuck
https://junegunn.github.io/fzf/shell-integration/
fzf is a nice tool for this and other things
I type the first few letters and use up arrow, or !start of command name
Doesn’t work on half the machines I use,and I am too lazy to find the setting/plugin to make it work.
Dude, that’s vanilla bash.
I don’t think it is…? You sure your distro doesn’t add some customizations? Neither of the features you mention work on two different distros I just tried it on (openSUSE and NixOS).
$ cat .inputrc $include /etc/inputrc "\e[A": history-search-backward "\e[B": history-search-forward
^R
history | grep ‘part of the command I remember’
Also: Ctrl+r then type the part of the command you remember.
Everytime I use ffmpeg…
Ha… That as if I would ever remember the part of the tool instead of the fact what it did 🤣
And then the command is just “su”
Alabado sea El Omnissiah.
Que paso que hay tanto comentario en Castellano? Pensé que eramos pocos los hispanohablantes
Hermano, nací en Estados Unidos. A pesar de que se dice que los estadounidenses solo sabemos inglés (y mis padres son de la India), saber hablar un poco de español es bastante útil.
Además, el OP publicó en castellano. Por lo tanto, me pareció pertinente y cortés comentar al respecto.
god I fucking love Linux (not a Linux thing) but I still fucking love Linux
If I haven’t ran it in a while or I don’t know it by heart then I ‘nano /home/mehblah/.bash_history’
I do
history | grep keyword
.I forget that exist. One problem with being really old school on linux is you don’t adopt new ways unless there is a reason to do so.
grep -i “whatever” .bash_history
you really should just ctrl + r and type and then ctrl + r to goto the next one back.
Huh. I didn’t know that one. It’s much more practical. Thanks for teaching me something today.
… And waste an opportunity to type on my ludicrously expensive mechanical keyboard?
FRIG no
Why are you making personal attacks against me.
Ctrl + R and start typing the command, it’ll come up, press enter. Im just more lazy because I know there are still faster ways.
Oh my freaking god thank you
Note: if the above isn’t working, you may need to first set your shell to accept emacs commands:
set -o emacs
Fuck that hits so hard.
Care to explain to an uninitiated?
Every time you hit the up arrow, it shows the previous command you used in the terminal.
So hitting the arrow once gives your last used, hitting it twice gives your second to last command, and so on.
Yup and that is me. I could just history grep the command I want but I SWEAR it was just 2 commands ago, or 15 up arrows. lol.
Ohhh! I can absolutely relate to this as well! Using a zmud client to play games on. which is probably not much different, looking, than a terminal anyways
Multi user dungeon? What do you play?
Nah just save all your commands in a text file on the desktop then make an alias to open it in nano so you just have to type “com”. Works for dumb ol me
Why not just make the alias command cat the file instead?
Edit: I wrote grep instead of cat
I’ll look into that