Impressions and INdT and OpenEmbedded29 Jun 2007 02:19 pm

Expect is a tool for automating interactive applications. Last year I suffered  trying to code some scripts using a pure expect language. I remember too that in that opportunity I used some pexpect (python module to automating interactive applications).

What I didn’t remember was how easy is to use the pexpect one.

It is amazing!

At pexpect home page you can see how easy it is. But I want to add my case as a new example:
import pexpect
child = pexpect.spawn(“dh_make -e %s -f %s” %
(“MAINTAINER”, d, 1) or
child.expect(‘Hit to confirm:’)

This is part of a code that I’m coding to make OpenEmbedded have full deb/dsc generation.

One Response to “pexpect”

  1. on 15 Aug 2007 at 9:01 am Fleury

    Haha. That’s way better than playing with TCL expect :-)

    Btw, põe um link aí pro meu blog Vivi :)


Trackback this Post | Feed on comments to this Post

Leave a Reply