this post was submitted on 04 Jul 2023
1235 points (98.5% liked)
linuxmemes
20948 readers
431 users here now
I use Arch btw
Sister communities:
- LemmyMemes: Memes
- LemmyShitpost: Anything and everything goes.
- RISA: Star Trek memes and shitposts
Community rules
- Follow the site-wide rules and code of conduct
- Be civil
- Post Linux-related content
- No recent reposts
Please report posts and comments that break these rules!
founded 1 year ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
This is my approach, and for those who don't know, you can use those line numbers that come back from
history
to rerun the command. Like if your output is something like this:You can run
!501
and it will just re-runls /tmp
Woah! I had no clue!
I got that as
hgrep
Yall are missing out on autocomplete.
didn't know there was a comment for that, I just always used cat to read the bash history file
Wait until you learn about ctrl-R to search the bash history... :) If you press that and start typing, you will get auto complete from previous commands you typed. This is how an experienced linux user can be so fast in the terminal.
There are even better tools for this, so ctrl R is just the built in way. Later you should look into https://github.com/junegunn/fzf