-
Notifications
You must be signed in to change notification settings - Fork 104
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
error 152 unexpect fi #26
Comments
Can you tell me what OS / environment / shell you are running please? |
Ubuntu 16.10 gave me this:
|
Same here on Ubuntu 17.10
|
@oleersoy - can you tell me what shell you are running with the following:
I'm also struggling to match up line "90" from the error message to a corresponding line in the script - I'm guessing that maybe the shell ignores comments, but I'm not sure. Also, can you make sure you are downloading the script, then executing it, e.g.
|
There are a number of issues in this shell script (give it a run through shellcheck -- https://www.shellcheck.net/). A few things to think about:
I think the main issue that's causing confusion is the use of the So for example, this sequence:
If this script is executed ( One thing you could do is only prompt if you know stdin is a tty... something like this works correctly when piped and executed directly:
If you look at the
Testing FD 0 (STDIN) correctly differentiates between terminal and piped input. |
Thanks very much @uberjay - I will look into that and see if I can resolve this issue... |
ran it and everything seemed to work fine, but got the error in the title.
The text was updated successfully, but these errors were encountered: