in reply to Re: Is any simple way to get the current direcoty name?
in thread Is any simple way to get the current directory name?
will print the same thing twice, which is probably not what you want. (If you use Cwd and ask it to override chdir, it will automatically keep $ENV{PWD} in sync with the actual current working directory, but by default it is not kept in sync).print $ENV{PWD},"\n"; chdir("..") print $ENV{PWD},"\n";
|
|---|