App-StaticImageGallery

 view release on metacpan or  search on metacpan

MANIFEST  view on Meta::CPAN

lib/App/StaticImageGallery/Image.pm
lib/App/StaticImageGallery/Style/Simple.pm
lib/App/StaticImageGallery/Style/Source/Dispatcher.pm
lib/App/StaticImageGallery/Style/Source/FromDir.pm
lib/App/StaticImageGallery/Style/Source/FromPackage.pm
t/00-load.t
t/01-Dir.t
t/02-Commands.t
t/boilerplate.t
t/images/JPEG.jpg
t/images/PNG.png
t/images/Source.pxm
t/images/sub_folder/JPEG.jpg
t/images/sub_folder/PNG.png
t/lib/App/StaticImageGallery/Style/Test.pm
t/pod-coverage.t
t/pod.t

lib/App/StaticImageGallery/Dir.pm  view on Meta::CPAN

                $self->msg_verbose(1,"Go into %s",$file);
                $self->add_dir(File::Basename::basename($file->stringify));

                my $args = $self->{init_args};
                $args->{work_dir} = $file;
                $args->{link_to_parent_dir} = 1;
                my $dir = App::StaticImageGallery::Dir->new(%$args);
                $dir->write_index;
            }
        }else{
            if ( $file->stringify =~ /.*(jpg|png|jpeg|tif)$/i ){
                $self->msg_verbose(10,"Push Image %s - %s",$self->work_dir,$file->basename);
                push @images, App::StaticImageGallery::Image->new(
                    dir      => $self,
                    original => $file->basename,
                    ctx      => $self->ctx,
                );
            }

        }
    }

t/01-Dir.t  view on Meta::CPAN


use Test::More;
use Imager;
foreach my $format (qw/jpeg png/){
    unless ( defined $Imager::formats{$format} ) {
        plan skip_all => "Missing $format support";
        last;
    }
}
plan tests => 34;
use_ok( 'App::StaticImageGallery' );
use_ok( 'App::StaticImageGallery::Dir' );

# ./maint/style_to_package.pl styles/Test > t/lib/App/StaticImageGallery/Style/Test.pm
use lib 't/lib';
my $work_dir = 't/images/';
my $data_dir = 't/images/.StaticImageGallery/';
my @images = sort ('JPEG.jpg','PNG.png');
my @default_ARGV = (
    # '--no-recursive',
    '--style' => 'Test',
    # '-vvvvv',
);
{
    local @ARGV;
    push @ARGV, @default_ARGV;
    push @ARGV, 'build';
    push @ARGV, $work_dir;



( run in 1.245 second using v1.01-cache-2.11-cpan-df04353d9ac )