this post was submitted on 12 Mar 2024
751 points (98.8% liked)
Programmer Humor
32557 readers
345 users here now
Post funny things about programming here! (Or just rant about your favourite programming language.)
Rules:
- Posts must be relevant to programming, programmers, or computer science.
- No NSFW content.
- Jokes must be in good taste. No hate speech, bigotry, etc.
founded 5 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
I know this is a meme, but I actually find
tar
fairly easy to remember.tar -xf $archive
is extract filetar -czf $archive dir/
is create zipped (compressed) file and the positional arguments are the files to add to the archive.And this is 99% of my usage. You can skip
-f $archive
to use stdin/stdout or use-C
to change directory (weird name but logically tar always extracts to the current directory). There is also a flag to list which I always forget and lookup each time, but I list much less often.-v
is useful for verbose.Overall there are much harder commands to remember.
find
always gets me if I go beyond-name
.ps
,tree
andls
(beyond-Al
) always get me to open the man page.That would be
-t
, which I tend to remember as "test", as in testing to see what is inside the archive!tealdeer is a great program to have installed for easily getting a breakdown of the flags of pretty much any CLI app that at least I can ever think of!