Re: Calling a dos batch file from python

2007-09-05 Thread Wesley Brooks
I looked into this a little while ago so I could get the MAC address of a machine while on linux or windows. Here's a simplified version that just does the windows side; self.macMatch = re.compile(r"((\w\w[:-]){5}\w\w)") data = os.popen("ipconfig /all", 'r') text = data.read() tup = self.macMatch.

Re: Calling a dos batch file from python

2007-09-05 Thread n o s p a m p l e a s e
On Sep 4, 5:01 pm, [EMAIL PROTECTED] wrote: > On Sep 4, 8:42 am, n o s p a m p l e a s e <[EMAIL PROTECTED]> > wrote: > > > Suppose I have a batch file called mybatch.bat and I want to run it > > from a python script. How can I call this batch file in python script? > > > Thanx/NSP > > The subproc

Re: Calling a dos batch file from python

2007-09-04 Thread kyosohma
On Sep 4, 8:42 am, n o s p a m p l e a s e <[EMAIL PROTECTED]> wrote: > Suppose I have a batch file called mybatch.bat and I want to run it > from a python script. How can I call this batch file in python script? > > Thanx/NSP The subprocess module should work. Mike -- http://mail.python.org/m

Calling a dos batch file from python

2007-09-04 Thread n o s p a m p l e a s e
Suppose I have a batch file called mybatch.bat and I want to run it from a python script. How can I call this batch file in python script? Thanx/NSP -- http://mail.python.org/mailman/listinfo/python-list