Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask

creating a folder

by chrisbarton (Initiate)
on Apr 09, 2002 at 16:21 UTC ( #157761=perlquestion: print w/replies, xml ) Need Help??

chrisbarton has asked for the wisdom of the Perl Monks concerning the following question:

I know this is pretty simple but I have just spent an hour searching and cannot find the answer:

how do I create a folder in perl?

Replies are listed 'Best First'.
Re: creating a folder
by earthboundmisfit (Chaplain) on Apr 09, 2002 at 16:23 UTC
    mkdir is your friend....

    update: It will work across platforms.

Re: creating a folder
by derby (Abbot) on Apr 09, 2002 at 16:23 UTC
    folder in Win32 or Mac? Unless I'm missing something, check out mkdir.


Re: creating a folder
by perlplexer (Hermit) on Apr 09, 2002 at 17:45 UTC
    File::Path if you need to create/remove directory trees.

Re: creating a folder
by DigitalKitty (Parson) on Apr 10, 2002 at 04:05 UTC
    Hi Chris,

    You could do this:
    $mkdir perlStuff, 0755 or warn "Could not create the perlStuff directo +ry: $!";


Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://157761]
Approved by VSarkiss
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others surveying the Monastery: (7)
As of 2022-10-04 09:48 GMT
Find Nodes?
    Voting Booth?
    My preferred way to holiday/vacation is:

    Results (16 votes). Check out past polls.