13,925 reputation
1130
bio website
location Ottawa, Canada
age
visits member for 3 years, 5 months
seen 4 hours ago

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


1d
comment Using sed to replace characters between two patterns
My thought was that you should not have to pre-process your data at all: thus Stephane and Gnouc have given you better answers.
1d
comment Using sed to replace characters between two patterns
Show us what you really have to work with. We can come up with something easy.
1d
answered Using sed to replace characters between two patterns
2d
comment How to I create a file with a sorted list from users that have mail
Is there a question you want to ask? unix.stackexchange.com/help/asking
2d
comment How to create CSV file without unnecessary spaces
I think your problem is that you're processing CSV in bash. You should be using a proper CSV parser that can handle these "problems" you're having. For example, reading the file in a "while read" loop will make it hard to handle embedded newlines (line 2) or lines with commas inside quotes (not present in your example data but likely in the real world).
Jul
25
revised How can I suppress the space between generated arguments during brace expansion?
added 268 characters in body
Jul
24
answered How can I suppress the space between generated arguments during brace expansion?
Jul
24
comment Find the exact string with grep
In that case, I'd use grep -q '^user1@example\.com\>' -- with a line anchor at the start, and an end-of-word anchor at the end.
Jul
24
comment Find the exact string with grep
Is the email the only word on a line?
Jul
23
answered List all the html tags in a file
Jul
23
comment How do I stop a bash shell PS1 color to stop at the end of the command?
You need to show us your prompt so we can pinpoint the errors.
Jul
22
comment “bash: [: : integer expression expected”
@mrgnw, please show the code that is causing the error
Jul
22
answered How to check a ksh script for syntax errors?
Jul
22
comment Reading through a csv file
Why is that? Calling perl from a shell script is exactly the same as calling awk or grep or cut or ...
Jul
22
answered Reading through a csv file
Jul
21
comment Passing arguments from a file to a bash script
Are you actually writing source test.sh "$arguments" with quotes? That would be one explanation for your description
Jul
21
revised Finding the number of time a particular number in a file where range also specified
added 129 characters in body
Jul
21
answered Finding the number of time a particular number in a file where range also specified
Jul
21
answered Print last element of each row
Jul
18
comment Short, simple command to create a group if it doesn't already exist?
Or just redirect it's output to /dev/null