4,957 reputation
11424
bio website mikelward.com
location Mountain View, CA
age 33
visits member for 4 years, 8 months
seen 2 days ago

Computer guy from Australia now living in the US.

Part sysadmin, part developer, part web developer.

My name is pronounced like "Michael".


Jan
18
comment Byzantine behaviour in shell script
I said use set -x because he was using the -x option. For consistency and because I think the set -<flag> form is more common than set -o <optname>.
Jan
18
comment Byzantine behaviour in shell script
He said he was using bash. This allows me to say use echo -e. Otherwise you really need printf for consistent behavior on all platforms, but that's an external command in bash, so echo -e is correct and faster in this case.
Jan
18
revised Byzantine behaviour in shell script
added 369 characters in body
Jan
18
comment Byzantine behaviour in shell script
+1. Tilde definitely needs escaping. Also agree there would be simpler ways to write this.
Jan
18
answered Byzantine behaviour in shell script
Jan
18
comment Ubuntu: Linux can browse sites, bash can't even resolve the dns name - Huh!
Yes, hence the question. :-)
Jan
18
answered Ubuntu: Linux can browse sites, bash can't even resolve the dns name - Huh!
Jan
18
answered Firefox 4 show tools menu in button interface
Jan
18
comment is it possible to open a new shell from a shell and switch between them?
@honk Thanks. Online man pages didn't mention suspend, but indeed it's there in bash 3.2. gnu.org/software/bash/manual/html_node/Bash-Builtins.html
Jan
18
answered is it possible to open a new shell from a shell and switch between them?
Jan
17
revised c shell environment variable error: “Bad : modifier in $”
added 239 characters in body
Jan
17
answered c shell environment variable error: “Bad : modifier in $”
Jan
17
awarded  Critic
Jan
17
comment How do I make sudo preserve my environment variables?
Not sure why you have to modify env_keep to keep PYTHONPATH. If !env_reset is in effect and there are no env_delete entries, that should be sufficient AFAIUI.
Jan
17
comment How do I make sudo preserve my environment variables?
What about env_delete? Also, man page says: Note that many operating systems will remove potentially dangerous variables from the environment of any setuid process (such as sudo).
Jan
17
comment How do I make sudo preserve my environment variables?
If sudo was compiled with --with-secure-path, that would be modifying PATH, but the docs don't say it touches LD_LIBRARY_PATH.
Jan
17
answered replacing dot in string, but leaving last one
Jan
17
comment how do I pipe to the “for” command?
@barlop, I just open up a command prompt, type help | more, and choose a command that sounds related (e.g. if) then run if /? or help if.
Jan
17
comment how do I pipe to the “for” command?
@barlop, yes, I will remove the tempfile suggestion. "pipeline" is a UNIX term meaning a series of commands with pipes in the middle.
Jan
17
comment how do I pipe to the “for” command?
Thanks neurolysis, will update my answer to include that.