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: > > C:\Python24\Python Scripts > C:\Python24\Python Scripts > > The cd never changed. . . Can somebody explain this? I think I need to > add something simple, i didnt quite get the example ' > os.system('./some --command') '
Read the documentation. os.system() opens up a new shell process. The command to change directories happens in that shell process, not python's process. Try another command. -- Robert Kern [EMAIL PROTECTED] "In the fields of hell where the grass grows high Are the graves of dreams allowed to die." -- Richard Harter -- http://mail.python.org/mailman/listinfo/python-list