Tuesday, September 14, 2010

chdir in perl for changing working directory

usage:
chdir EXPR
chdir(EXPR)

Changes the working directory to EXPR, if possible. If EXPR is omitted, changes to directory specified by $ENV{HOME}, if not set, changes to $ENV{LOGDIR} directory . if none of these is set then does nothing.

Returns 1 upon success, 0 otherwise.
Example:
chdir("C:\temp\working_dir\");

No comments:

Post a Comment