I've recently written a module that I have titled "Dir::TreeBuild" and
would like to contribute it to CPAN.  Its functionality definately would
belong in the 'Dir' namespace, so I wanted to converse with you to see
if you'd be interested in allowing me to do so, since I assume 'Dir' is
your namespace.

For your inconvenience, here is the current POD documentation:

<SNIPPET>

NAME
    Dir::TreeBuild - Perl extension for creating directory trees

SYNOPSIS
    use Dir::TreeBuild;

    %tree = ( 'level1' => { 'down1a' => {}, 'down1b' => { 'down2a' =>
{},
    'down2b' => {} }, 'down1c' => {} }, 'level2' => {} );

    $tree = Dir::TreeBuild->new(struct => \%tree, top => $path );

    $tree = new Dir::TreeBuild;

    $tree->top($path);

    $top = $tree->top;

    $tree->struct(\%tree);

    %tree = $tree->struct;

    $tree->umask($octal);

    $tree->build;

    $tree->deltree;

DESCRIPTION
    Dir::TreeBuild provides the capabilities of easily creating a
directory
    tree.

    new

    Constructor for the Dir::TreeBuild object. Accepts the following
    options:

    *struct* - hash reference that defines the desired directory
structure

    *top* - the directory that the desired directory structure is to be
    created in. The current directory is the default.

    A 'Dir::TreeBuild' object is returned.

    top

    Accessor method to read/write the top level directory in a
    Dir::TreeBuild object.

    To read the value: $tree->top;

    To write the value: $tree->top($value);

    struct

    Accessor method to read/write the directory structure in a
    Dir::TreeBuild object.

    To read the value: $tree->struct;

    To write the value: $tree->struct(\%tree);

    umask

    Accessor method to read/write the current umask value for the
specified
    Dir::TreeBuild object (see the umask manpage). When the object is
built
    (see the build method), it is built using this umask; upon
completion of
    the build, the original process umask is reverted to.

    To read the value: $tree->umask;

    To write the value: $tree->umask($octal);

    build

    Once a Dir::TreeBuild object has been created and initialized (with
at
    least a structure), the build method is responsible for actually
    creating the directory tree.

    The permissions of each directory in the tree are rwxrwxrwx (0777)
by
    default, but the current umask of the process is used to mask out
the
    undesired bits. The umask can be set with the umask method.

    $tree->build;

    deltree

    Once a directory has been created, it can be deleted with the
deltree
    method. If the directory is not empty, it will not be deleted; the
    deltree command will continue until all directories described in the
    Dir::TreeBuild structure have been traversed.

    This execution method does not accept any parameters.

    $tree->deltree;

  EXPORT

    None.

AUTHOR
    Ray Graham, Jr., <[EMAIL PROTECTED]>

</SNIPPET>

I've been using Perl for years, but have not produced anything that I've
felt has been worthy enough of submitting to CPAN until maybe now --
this Dir::TreeBuild module being one of them.  Would you be willing to
colaborate with me on this?

Thanks!

-- 
          +---------------------------------------------------+
          | Ray Graham, Jr.         | LSI Logic Corporation   | 
          | Design Engineer         | 1551 McCarthy Blvd      |
          | [EMAIL PROTECTED]        | MS G-780                |
          | O: 408-433-8005         | Milpitas, CA 95035      |
          | M: 650-270-9563         | http://www.lsilogic.com |
          +---------------------------------------------------+




Reply via email to