17,770 reputation
1540
bio website
location Ottawa, Canada
age
visits member for 3 years, 10 months
seen 14 hours ago

Developer at Pythian.
Big Tcl and Perl fan.
Enjoy Ruby and JavaScript too.


2d
comment Increment numeric pattern in file
true, but we're going on the OP's statement that the original file has one line.
2d
answered Increment numeric pattern in file
2d
comment Increment numeric pattern in file
How many duplications? Does the first file always have 0001?
Dec
16
comment What is the purpose of using shift in bash scripts?
The definitive reference: gnu.org/software/bash/manual/bashref.html#index-shift
Dec
16
comment awk array using number as value did not work
@Karli, updated
Dec
16
revised awk array using number as value did not work
added 404 characters in body
Dec
16
revised awk array using number as value did not work
added 18 characters in body
Dec
16
answered awk array using number as value did not work
Dec
16
answered Extract multiple instances of text between two strings
Dec
16
comment awk array using number as value did not work
Please actually show your ideal output.
Dec
16
revised awk array using number as value did not work
format code
Dec
16
comment Need to swap the -(minus) sign for only numbers and not text for a given row
With non-gnu, you should be able to use [^[:alnum:]_]
Dec
15
comment Start script on boot up?
duplicate: askubuntu.com/q/561604/10127
Dec
14
comment bash: What is the difference between these two script variants?
echo "reading entry: "$f"" -- the variable is NOT quoted. You're echoing the concatenation of 3 strings: "reading entry: ", the unquoted $f and then an empty string "". You want to put the variable inside quotes: echo "reading entry: $f"
Dec
13
comment delete files having a certain pattern in their names
Ack. I didn't see sputnick changing his answer. Alright: -exec rm {} \; has to spawn an new process for rm for each file found. -delete is built-in to find, so it will be more efficient.
Dec
13
comment delete files having a certain pattern in their names
@edwardtorvalds, in quotes, it's a literal string. Without quotes, it will expand to match filenames.
Dec
13
comment delete files having a certain pattern in their names
@mattdm, d'oh! of course, thanks
Dec
13
comment delete files having a certain pattern in their names
If it's just files in the current dir, simply rm '[0-9][0-9].*'
Dec
13
answered understanding sed, awk and curl interaction extracting ssh URL information from github page
Dec
12
answered Find files newer than a day and copy