Gerard Flanagan wrote: > On Jun 7, 8:39 am, dmitrey <[EMAIL PROTECTED]> wrote: >> Hi all, >> I guess this question was asked many times before, but I don't know >> keywords for web search. >> >> Thank you in advance, D. > > import os > > d1 = os.path.dirname(__file__) here I get an error "__file__" is not defined ?? > d2 = os.path.dirname(os.__file__) here I get a completely different path ?? > > print d1 > print d2
This seems to work (but I doubt it's always working !! ) print os.getcwd() so what's the real answer ? thanks, Stef Mientki -- http://mail.python.org/mailman/listinfo/python-list