Reputation
Next tag badge:
399/400 score
103/80 answers
Badges
17 139 280
Newest
 Nice Answer
Impact
~4.1m people reached

May
8
comment Delete text from a file using regular expressions
You have <!!!> in one and </!!! in the other. Make up your mind. Also do you mean that those spaces, newlines and "``` have to be removed?
May
8
revised Delete text from a file using regular expressions
added 110 characters in body
May
8
answered Delete text from a file using regular expressions
May
8
comment Overwriting files found by find?
What you save in wall-clock time by running things in parallel you lose in cpu time as parallel has a misfeature in that is spawns a shell ($SHELL, not sh) to run those commands. Also note that it won't work if the file names contain newline characters, or possibly other characters depending on you $SHELL (for instance, it fails to escape = globs in zsh and ^ in the Bourne shell). You may want to run it with SHELL=/bin/sh (or SHELL=/usr/xpg4/bin/sh on Solaris 10 and earlier) to avoid surprises.
May
8
revised Overwriting files found by find?
added 112 characters in body
May
8
answered Overwriting files found by find?
May
8
comment Overwriting files found by find?
No, busybox find doesn't have -execdir, nor does it have standard predicates like -ok or -nouser (so could be considered off-topic here). The OP did use -execdir. With -exec, the answer is wrong though, you'd need to use $(dirname...)/$(basename...) or use the shell's ${var%.gif} form.
May
8
revised Overwriting files found by find?
basename removes the dirname, so you need the (non-standard but common) -execdir, and -- for GNU cp.
May
8
revised Overwriting files found by find?
remove erroneous note about %% being bash specific.
May
8
revised When does cat finish reading from a pipe?
added 179 characters in body
May
8
revised Overwriting files found by find?
missing quotes, adding . and s/-not/!/ for portability.
May
8
comment How to ensure that string interpolated into `sed` substitution escapes all metachars
@Menon, double quotes are not special to sed, you don't need to escape them.
May
8
answered When does cat finish reading from a pipe?
May
7
answered Find the last occurence of a string in a given filetype in all subdirectories
May
7
revised Copy line in file if we know the pattern
added 36 characters in body
May
7
answered Copy line in file if we know the pattern
May
7
comment How does cd .. know which directory is ..?
You might find these interesting: unix.stackexchange.com/a/79621 and unix.stackexchange.com/a/61513
May
7
comment How does cd .. know which directory is ..?
foo/bar/.. and foo may not be the same inode if foo or foo/bar are symlinks.
May
7
comment How does cd .. know which directory is ..?
That's not true of cd (in most shells except the Bourne shell), that does a logical handling of .. regardless of the .. hard link. You need cd -P for cd to chdir into the .. directory. See unix.stackexchange.com/a/61513
May
7
comment What characters should I escape while modifying a file using sed?
See unix.stackexchange.com/q/129059