perl-begin /


use strict;
use warnings;

use HTML::Latemp::GenMakeHelpers;
use File::Find::Object::Rule;

my $generator = 
        'hosts' =>
                'id' => "common",
                'source_dir' => "common",
                'dest_dir' => "\$(TARGET)",
                'id' => "berlios",
                'source_dir' => "src",
                'dest_dir' => "\$(TARGET)",

    open my $out_fh, ">", "p4n.mak";

    my @targets;
    foreach my $part_idx (1 .. 4)
         # find all the .pm files in @INC
         my @files = 
                        ->exec(sub { 
                                $_[0] ne "index\.html" 
        foreach my $f (@files)
            my $target = $f;

            # print $f, "\n";
            $target =~ s{\Alib/}{};
            $target =~ s{/lect(\d+)-all-in-one/}{/part$1/};
            $target = "\$(BERLIOS_DEST)/$target";

            push @targets, $target;

            print {$out_fh} "$target: $f\n\tmkdir -p `dirname \$\@`\n\tcp -f \$< \$\@\n\n";

    my $makefile_var_name = "DEST_TUTORIALS_PERL_FOR_NEWBIES_TARGETS";

    print {$out_fh} "$makefile_var_name = " . join(" ", @targets) . "\n\n";

    print {$out_fh} "perl_for_newbies_extra_data: \$($makefile_var_name)\n\n";

Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.