Great article but this shouldn't be called "Tricks" it should be called Shell Basics. I'm old enough to remember taking an Intro To Unix course and there was an entire day on the shell where these types of commands were presented as essential learning.
Technology
This is a most excellent place for technology news and articles.
Our Rules
- Follow the lemmy.world rules.
- Only tech related news or articles.
- Be excellent to each other!
- Mod approved content bots can post up to 10 articles per day.
- Threads asking for personal tech support may be deleted.
- Politics threads may be removed.
- No memes allowed as posts, OK to post as comments.
- Only approved bots from the list below, this includes using AI responses and summaries. To ask if your bot can be added please contact a mod.
- Check for duplicates before posting, duplicates may be removed
- Accounts 7 days and younger will have their posts automatically removed.
Approved Bots
alias please='sudo !!' would that work?
Edit: nope. Why not?
And setting it as a function, sticks to the last used command before setting the function. Fuck.
Nothing gets my nerdrage on more than using CTRL+w in a browser-based shell and closing the tab.
Yeah, annoying that it has different meanings.
This is a good article, especially if you're the lucky 10,000.
I was one of the 10 000. Again!
I am too - every single day. If I didn't know better, I'd think I'm stupid.
I know better, I am stupid ^__^
edit: evidence of my stupidity is that I couldn't even get one of those emoji faces done right
Please make the site respect my color setting by default.

It's a sunny spring day.
~~I was expecting some cool Mario strats~~
I'm always using "clear" to just get rid of my console's output. I think it has something to do with me remembering I used that on my old 80's computer, trying it out on a bash long after that and "oh, that works here too, that's convenient".
Reset looks like it does more stuff, but I don't know if that's useful for this use case.
I asked this myself, too. AI response:
clear: clears the visible screen (sends the terminal’s “clear” sequence); usually fast and does not change terminal settings or fully reinitialize scrollback.
reset: fully reinitializes the terminal (sends init strings, resets modes/attributes, may reconfigure terminfo/baud, and clears); slower and used to recover from garbled output or broken state.