Help for this page

Select Code to Download


  1. or download this
    use Path::Class;
    # maybe $DIR is read from a configuration file or passed in from anoth
    +er tool
    my $d = dir($DIR);
    $d = $d->parent->subdir("bar"); # one "right" way to do path manipulat
    +ion
    my $p = $d=~/\/$/ ? "$d" : "$d/";
    
  2. or download this
    require File::Spec::Unix;
    my $x = File::Spec::Unix->catdir('foo','bar').'/';