212
submitted 7 months ago by cybercitizen4@lemm.ee to c/asklemmy@lemmy.ml
(page 3) 50 comments
sorted by: hot top controversial new old
[-] macattack@lemmy.world 5 points 7 months ago* (last edited 7 months ago)

Getting cheatsheets via curl cheat.sh/INSERT_COMMAND_HERE

No install necessary, Also, you can quickly search within the cheatsheets via ~. For example if you copy curl cheat.sh/ls~find will show all the examples of ls that use find. If you remove ~find, then it shows all examples of ls.

I have a function in my bash alias for it (also piped into more for readability):

function cht() { curl cheat.sh/"$1"?style=igor|more }

[-] 10_0@lemmy.ml 5 points 7 months ago
[-] alsimoneau@lemmy.ca 5 points 7 months ago* (last edited 7 months ago)
load more comments (1 replies)
[-] plumcreek@lemmy.ml 5 points 7 months ago

qmv -f do ${dir}

... for quickly moving and renaming files. The default 'qmv' opens up your preferred text editor with a list of the source and destination name of the directory of files you want to move/rename. The '-f do' tells the command we only want to see/edit the [d]estination [o]nly. If you need to rename/move a bunch of files, it's much quicker to do it in vim (at least for me).

load more comments (1 replies)
[-] CameronDev@programming.dev 4 points 7 months ago
load more comments (1 replies)
[-] z3rOR0ne@lemmy.ml 4 points 7 months ago* (last edited 7 months ago)

locate, from the mlocate package. So useful. Honorable mention goes out to tldr.

[-] squid_slime@lemm.ee 4 points 7 months ago

du -sh /too/bar to get size of files/folders. sudo !! inserts sudo into previous command when forgotten. yay for full system update if yay is installed. cat reads files.

[-] pyr0ball@sh.itjust.works 4 points 7 months ago* (last edited 7 months ago)

Going to shamelessly plug my custom bashrc setup which has a ton of little scripting helpers and a few useful aliases. Remember to clone recursively if you want to try it out. (Still very much a work in progress, but it's getting to be pretty robust)

https://GitHub.com/pyr0ball/PRbL-bashrc.git

[-] jbrains@sh.itjust.works 3 points 7 months ago
load more comments (1 replies)
[-] this@sh.itjust.works 3 points 7 months ago

not sure if it counts as a command, but i use the up arrow to scroll through previous commands like, almost every time I open a terminal.

load more comments (1 replies)
[-] friend_of_satan@lemmy.world 3 points 7 months ago* (last edited 7 months ago)

compgen -back to see all valid things you can type into a shell.

[-] FrostyCaveman@lemm.ee 3 points 7 months ago
[-] SorteKanin@feddit.dk 3 points 7 months ago

Zoxide, dust, fd, rg, btm, tokei. So many newer Rust tools that are way better than the old stuff.

[-] ColdWater@lemmy.ca 3 points 7 months ago
load more comments (1 replies)
load more comments
view more: โ€น prev next โ€บ
this post was submitted on 21 Sep 2024
212 points (100.0% liked)

Asklemmy

48076 readers
441 users here now

A loosely moderated place to ask open-ended questions

Search asklemmy ๐Ÿ”

If your post meets the following criteria, it's welcome here!

  1. Open-ended question
  2. Not offensive: at this point, we do not have the bandwidth to moderate overtly political discussions. Assume best intent and be excellent to each other.
  3. Not regarding using or support for Lemmy: context, see the list of support communities and tools for finding communities below
  4. Not ad nauseam inducing: please make sure it is a question that would be new to most members
  5. An actual topic of discussion

Looking for support?

Looking for a community?

~Icon~ ~by~ ~@Double_A@discuss.tchncs.de~

founded 6 years ago
MODERATORS