Re: unexpected script output

2013-01-03 Thread berenger . morel
Except that I must be root to do that, it does not hurt me, so I did not investigate further. Give sudo a try. I will do. But I will also find how to only give me su rights for stuff like networkpower, not for everything, becoming su for system administration reminds me to take care when my

Re: unexpected script output

2012-12-31 Thread Bob Proulx
berenger.mo...@neutralite.org wrote: Bob Proulx wrote: I have seen various wifi drivers not be happy across a suspend/hibernate resume. I have needed to unload them on the way down and reload them on the way up. Or unload and reload them after the resume. Generally speaking, my computer

Re: unexpected script output

2012-12-28 Thread berenger . morel
I have seen various wifi drivers not be happy across a suspend/hibernate resume. I have needed to unload them on the way down and reload them on the way up. Or unload and reload them after the resume. Generally speaking, my computer have some troubles to automatically change used networks,

Re: unexpected script output

2012-12-27 Thread Bob Proulx
berenger.mo...@neutralite.org wrote: Wow. 1-4 times a day? Usually: 1: when I am moving from train to work 2: when I am leaving work to train 3: when I am moving from train to home 4: when I am leaving computer for bed :) Ah, I see. It isn't because the machine is unstable or needs it

Re: unexpected script output

2012-12-25 Thread berenger . morel
Wow. 1-4 times a day? Usually: 1: when I am moving from train to work 2: when I am leaving work to train 3: when I am moving from train to home 4: when I am leaving computer for bed :) Why is it necessary to reboot? I would like to understand this use case better. I am using

Re: unexpected script output

2012-12-24 Thread Bob Proulx
berenger.mo...@neutralite.org wrote: Bob Proulx a écrit: berenger.mo...@neutralite.org wrote: The immediate problem to change the symlink to bash instead of dash is that it will slow down his system boot sequence, ... I sometimes hear this but I disagree that boot speed causes this to

Re: unexpected script output

2012-12-21 Thread berenger . morel
Le 20.12.2012 01:32, Bob Proulx a écrit : berenger.mo...@neutralite.org wrote: Bob Proulx a écrit : Don't change the symlink. Change the #! line to #!/bin/bash. That is the correct way to use bash specific features. Then it will work on the next system that you run it on. If you change

unexpected script output

2012-12-19 Thread Nelson Green
Good morning, Can anyone help me understand why the following two console commands each produce output, but only one of them produces output when both are called in a shell script? $ /bin/echo Shell: $SHELL Shell: /bin/bash $ /bin/echo Random: $RANDOM Random: 29707 $ cat output.sh #!/bin/sh

Re: unexpected script output

2012-12-19 Thread David Guntner
Nelson Green grabbed a keyboard and wrote: Good morning, Can anyone help me understand why the following two console commands each produce output, but only one of them produces output when both are called in a shell script? $ /bin/echo Shell: $SHELL Shell: /bin/bash $ /bin/echo

Re: unexpected script output

2012-12-19 Thread Glenn English
On Dec 19, 2012, at 9:07 AM, David Guntner wrote: 'Cause /bin/sh points to dash, not bash, in Debian. In squeeze, but not in lenny. It's bash in lenny: ls -la /bin/sh lrwxrwxrwx 1 root root 4 Oct 27 14:09 /bin/sh - dash ls -la /bin/sh lrwxrwxrwx 1 root root 4 2008-11-26 11:33 /bin/sh -

RE: unexpected script output

2012-12-19 Thread Nelson Green
Nelson Green grabbed a keyboard and wrote: Good morning, Can anyone help me understand why the following two console commands each produce output, but only one of them produces output when both are called in a shell script? $ /bin/echo Shell: $SHELL Shell: /bin/bash $

RE: unexpected script output

2012-12-19 Thread Nelson Green
On Dec 19, 2012, at 9:07 AM, David Guntner wrote: 'Cause /bin/sh points to dash, not bash, in Debian. In squeeze, but not in lenny. It's bash in lenny: ls -la /bin/sh lrwxrwxrwx 1 root root 4 Oct 27 14:09 /bin/sh - dash ls -la /bin/sh lrwxrwxrwx 1 root root 4 2008-11-26 11:33

SOLVED save time output to a script variable (was RE: unexpected script output)

2012-12-19 Thread Nelson Green
Thanks Dave! PS, I'm getting ready to post a request for help in capturing the output of time to a script variable. I can't seem to make it work despite many different attempts. I don't think that's a dash issue, but if you know that it is, let me know. Well, that didn't take long. I'm

Re: unexpected script output

2012-12-19 Thread David Guntner
Glenn English grabbed a keyboard and wrote: On Dec 19, 2012, at 9:07 AM, David Guntner wrote: 'Cause /bin/sh points to dash, not bash, in Debian. In squeeze, but not in lenny. It's bash in lenny: ls -la /bin/sh lrwxrwxrwx 1 root root 4 Oct 27 14:09 /bin/sh - dash ls -la /bin/sh

Re: unexpected script output

2012-12-19 Thread David Guntner
[You know, it would be *really* nice if you set your mail program to include an attribute line at the top, indicating who you're replying to/quoting :-)] Nelson Green grabbed a keyboard and wrote: [I said...] Nelson Green grabbed a keyboard and wrote: $ cat output.sh #!/bin/sh /bin/echo

Re: unexpected script output

2012-12-19 Thread Bob Proulx
Nelson Green wrote: Nelson Green grabbed a keyboard and wrote: Change your shebang line to #!/bin/bash to make it work right and then set the executable bit on the script. Then you can just do ./output.sh to get the expected results (don't do sh output.sh, since that will just invoke

Re: unexpected script output

2012-12-19 Thread berenger . morel
Le 20.12.2012 00:22, Bob Proulx a écrit : Nelson Green wrote: Nelson Green grabbed a keyboard and wrote: Change your shebang line to #!/bin/bash to make it work right and then set the executable bit on the script. Then you can just do ./output.sh to get the expected results (don't do sh

Re: SOLVED save time output to a script variable (was RE: unexpected script output)

2012-12-19 Thread Bob Proulx
Nelson Green wrote: Well, that didn't take long. I'm posting a simple script that captures the system time output of the time command to a variable in case anyone else has spent a good bit of time trying to get this to work, like me. I have a few comments. Many eyes make all bugs visibile!

Re: unexpected script output

2012-12-19 Thread Bob Proulx
berenger.mo...@neutralite.org wrote: Bob Proulx a écrit : Don't change the symlink. Change the #! line to #!/bin/bash. That is the correct way to use bash specific features. Then it will work on the next system that you run it on. If you change the symlink on The immediate problem to