[Tutor] Invoking bash from python

William Mhlanga reddazz at gmail.com
Mon Aug 7 13:26:40 CEST 2006


I think I found a solution to my problem and thats to use the os module (
os.system function). I'm still open to any suggestions you may have.

--Will

On 8/7/06, William Mhlanga <reddazz at gmail.com> wrote:
>
> I'd like to write an app that helps a user install a program on Linux
> after fetching it from a remote site. The program is packaged as a bin file
> and when run from bash, the user has to agree to a licence agreement by
> entering "y" or "n" and enter a path for installation. It seems like I need
> to find a way for my program to invoke bash so that the user can enter the
> input required. So far, I've figured out that I can use urllib to fetch the
> file and the commands module to execute some system commands. Any ideas on
> how I can envoke bash and pass on the users input to bash.
>
> Thanks for your input.
>
> Will
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.python.org/pipermail/tutor/attachments/20060807/92d3b69d/attachment.htm 


More information about the Tutor mailing list