jw013

United States

Debian user, GNU/Linux enthusiast, FLOSS supporter, hobby developer.

Aug
26
comment How to remove a single line from history?
@Moberg $num is a shell parameter (a.k.a. variable). I can see how my example would be confusing if you didn't know about shell parameter expansion, so I edited the code to use a concrete example instead.
Aug
26
revised How to remove a single line from history?
removed `$num` as it confused people unfamiliar with $ parameter expansion
Aug
18
awarded Nice Answer
Aug
2
awarded Yearling
Aug
2
awarded Yearling
Jul
29
awarded Yearling
Jul
29
awarded Yearling
Jul
28
comment Find -exec + vs find | xargs. Which one to choose?
I don't see how -0 is more of a pain than --delimiter "\n".
Jul
24
awarded Yearling
Jul
24
awarded Yearling
Jul
21
awarded Yearling
Jul
21
awarded Yearling
Jun
23
reviewed Reviewed PuTTY does not connect over SSH; other clients work fine
Jun
23
awarded Enlightened
Jun
23
comment adding text to filename before extension
@SargeBorsch What do you need explained? My answer, the snippet in the question, and Doug's answer are only differ by a few characters, and Doug's answer explains even less than mine so I don't know what it is you want. If you just compare the difference in the two outputs in the question it should be trivially easy to figure out what they do. I can explain why my answer is preferable to Doug's. 1. I use printf with a format string instead of the less portable echo. 2. I use parameter expansion which is more efficient than calling an external binary (basename) for such a simple task.
Jun
15
awarded Supporter
Jun
15
awarded Autobiographer
Jun
11
awarded Autobiographer
Jun
9
awarded Notable Question
Jun
7
awarded Guru
1 2 3 4 5