According to the chdir manual, if possible, change the working directory to EXPR .
This script, when executed from cmd.exe:
my $path = 'C:\\some\\path\\'; print "$path\n"; chdir("$path") or die "fail $!";
leads to this result:
C:\some\path\
but when I return to the command line, I am still in the source directory. I do not understand the purpose of chdir?
source share