You did not specify, how you install Gimp, so it is difficult to recommend a suitable solution. Usual install scripts return a non-zero exit code, which you might want to catch. Others might output something to stderr to indicate failure, so you can evaluate this.
> Not sure if this statement is supported on the ActivePerl
I wouldn't call __END__ a "statement", but ... yes, it is Perl standard, and works well with ActiveState Perl too.
You posted this in the wrong forum. This forum is intended for Perl problems, so you probably won't get much help.
As of your problem, I would do a perror to get more information.
(Crossposting note: I have already posted this article on comp.lang.tcl on the 3 days ago. This is posted here again, because I didn't get any response on my original article so far).
I use the following script on Solaris to log into a remote host:
spawn ssh other@[exec uname -n]
expect {$}...
>> How do you signal EOF?
> Ctrl-D on a blank line.
For completeness, we should mention that this is true on Unix-like systems. For Windoze CMD shell, for instance, it would be Ctrl-Z. Though the #! line of the OP's program suggests that he is indeed using such a system, we can not conclusively...
> Strangely, the OPs code worked fine for me unmodified.
Well, if the OP really used his code from the command line,
maybe he simply forgot to signal EOF to STDIN....
> How can you make such a generalisation? It depends entirely on how the script is normally invoked.
Exactly that's the point. The OP does not reveal how s/he normally invokes the script, hence we can not assume that STDOUT connects to a terminal. That's what "In general..." means.
BTW, it's...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.