Re: How to run commands in command line from a script

2005-07-01 Thread Peter Hansen
Ivan Shevanski wrote: > Well, the thing is that I was just using changing directories as an > example for running a name specific command, is the here> the only way to run name specific commands? An example would be > (what I am actually trying to do) run the simply command > mame s1945 > in the

Re: How to run commands in command line from a script

2005-07-01 Thread Ivan Shevanski
Well, the thing is that I was just using changing directories as an example for running a name specific command, is the the only way to run name specific commands? An example would be (what I am actually trying to do) run the simply command mame s1945 in the command line. MAME is, for those o

Re: How to run commands in command line from a script

2005-07-01 Thread Mike Meyer
Peter Hansen <[EMAIL PROTECTED]> writes: > Ivan Shevanski wrote: >> Alright well I'm quite a noob and when I run a simple command to >> change the current directory, nothing happens. I made a little test >> script to show it: >> import os >> cwd = os.getcwd() >> print cwd >> os.system('cd = C:\Pr

Re: How to run commands in command line from a script

2005-06-30 Thread Peter Hansen
Peter Hansen wrote: > Ivan Shevanski wrote: >> Alright well I'm quite a noob and when I run a simple command to >> change the current directory, nothing happens. I made a little test >> script to show it: > > Generally, the only way to use an application (i.e. a program like the > Python inter

Re: How to run commands in command line from a script

2005-06-30 Thread Peter Hansen
Ivan Shevanski wrote: > Alright well I'm quite a noob and when I run a simple command to change > the current directory, nothing happens. I made a little test script to > show it: > > > import os > cwd = os.getcwd() > print cwd > os.system('cd = C:\Program Files') > print cwd There are at lea

Re: How to run commands in command line from a script

2005-06-30 Thread Robert Kern
Ivan Shevanski wrote: > Alright well I'm quite a noob and when I run a simple command to change > the current directory, nothing happens. I made a little test script to > show it: > > import os > cwd = os.getcwd() > print cwd > os.system('cd = C:\Program Files') > print cwd > > then the result

Re: How to run commands in command line from a script

2005-06-30 Thread Ivan Shevanski
n-list@python.org Subject: Re: How to run commands in command line from a script Date: Thu, 30 Jun 2005 20:01:29 -0700 Ivan Shevanski wrote: > I know there is an easy way to do this, and I just can not remember. I have > already searched where I thought the module would be. . . I just want t

Re: How to run commands in command line from a script

2005-06-30 Thread Devan L
The code module, perhaps? http://www.python.org/doc/2.4.1/lib/module-code.html -- http://mail.python.org/mailman/listinfo/python-list

Re: How to run commands in command line from a script

2005-06-30 Thread Robert Kern
Ivan Shevanski wrote: > I know there is an easy way to do this, and I just can not remember. I have > already searched where I thought the module would be. . . I just want to run > some name specific commands. Is this easily possible? Quick and dirty: import os os.system('./some --comman

How to run commands in command line from a script

2005-06-30 Thread Ivan Shevanski
I know there is an easy way to do this, and I just can not remember. I have already searched where I thought the module would be. . . I just want to run some name specific commands. Is this easily possible? Thanks, -Ivan _ Expres