Re: Interactive Expect from bash Script

2014-03-28 Thread Mike Frysinger
On Sat 29 Mar 2014 04:26:37 Esben Stien wrote: > Any pointers as to what I can try? if you don't mind me asking, what's with the mixing of languages ? seems like you could accomplish all of this with python alone. are you aware of the pexepct module ? http://pexpect.sourceforge.net/ i

Interactive Expect from bash Script

2014-03-28 Thread Esben Stien
I'm trying to use expect inside a bash script that accepts an ssh url, like this: ssh-url.sh ssh://foo:bar@baz The expect code works fine when executed outside the bash script, but when executed like this, the script just prompts instead of logging me in. I believe the bash scripts hands over

Re: /dev/fd/62: No such file or directory

2014-03-28 Thread Linda Walsh
Eduardo A. Bustamante López wrote: On Fri, Mar 28, 2014 at 08:21:40AM -0700, Linda Walsh wrote: Isn't it only things that are like "read xxx < <(cmd)" ? or is there something else that uses process substitution?? <(cmd) and >(cmd) are process substitutions. If you want to work around, use na

Re: /dev/fd/62: No such file or directory

2014-03-28 Thread Eduardo A . Bustamante López
On Fri, Mar 28, 2014 at 08:21:40AM -0700, Linda Walsh wrote: > I just checked... it is partly my fault in that I > upgraded my bash from 4.2 -> 4.3 to get around a limitation in 4.2. > Am not looking forward to upgrading to 4.4, since both times I've tried, > autocompletion completely broke a

Re: /dev/fd/62: No such file or directory

2014-03-28 Thread Greg Wooledge
On Fri, Mar 28, 2014 at 08:21:40AM -0700, Linda Walsh wrote: > What I'd prefer to see is that bash do what you say at > runtime, rather being limited to that choice at build time. If you require process substitution features in a script that may be executed when the OS is not fully booted, I

Re: /dev/fd/62: No such file or directory

2014-03-28 Thread Chet Ramey
On 3/28/14, 11:21 AM, Linda Walsh wrote: > > > Greg Wooledge wrote: >> On Thu, Mar 27, 2014 at 07:31:31PM -0700, Linda Walsh wrote: >>> So whether or not to use /def/fd is a build time option? >> >> On many commerical Unix systems (which don't have /dev/fd/), Bash >> falls back to using named

Re: /dev/fd/62: No such file or directory

2014-03-28 Thread Linda Walsh
Greg Wooledge wrote: On Thu, Mar 27, 2014 at 07:31:31PM -0700, Linda Walsh wrote: So whether or not to use /def/fd is a build time option? On many commerical Unix systems (which don't have /dev/fd/), Bash falls back to using named pipes. --- Right... but this is a case where

Re: /dev/fd/62: No such file or directory

2014-03-28 Thread Greg Wooledge
On Thu, Mar 27, 2014 at 07:31:31PM -0700, Linda Walsh wrote: > So whether or not to use /def/fd is a build time option? On many commerical Unix systems (which don't have /dev/fd/), Bash falls back to using named pipes. > It's a minority of scripts but have noticed the message > in som

Re: #!path

2014-03-28 Thread Jose Soares
Hi Greg, The links you pointed me are great. They were exactly what I was looking for. Thanks a lot.:-) j On 03/27/2014 06:32 PM, Greg Wooledge wrote: On Thu, Mar 27, 2014 at 08:19:39AM -0700, esoj wrote: I need to specify a variable path after #! but seems to me that bash can't do this. For