App-Duppy

 view release on metacpan or  search on metacpan

lib/App/DeDuppy.pm  view on Meta::CPAN

                push @{$self->paths}, $argument;

            } else {

                $self->set_subcommand($argument);

            }

        }

    }

    my $json = JSON->new->pretty->encode({ %{$self->options}, paths => $self->paths });
    if ($self->is_output_set) {
        open my $fh, '>', $self->output
            or croak sprintf(q{Cannot open '%s' for writing: %s},
                             $self->output, $!);
        $fh->print($json);
        $fh->close;
    } else {
        print $json;
    }

}


1;

__END__
=pod

=head1 NAME

App::DeDuppy - generate json files from casperjs test arguments

=head1 VERSION

version 0.05

=head1 SYNOPSIS

  # will build json files used by duppy
  deduppy --option1=value1 --option2=value2 --output=toafile.json

=head1 DESCRIPTION 

This is the companion script to L<duppy>, which role is to ease the process of building up json files used by duppy.

It makes no assumption about the validity of the options you are passing, so you should better be careful. 

=head1 AUTHORS

=over 4

=item *

Emmanuel "BHS_error" Peroumalnaik

=item *

Fabrice "pokki" Gabolde

=back

=head1 COPYRIGHT AND LICENSE

This software is copyright (c) 2014 by E. Peroumalnaik.

This is free software; you can redistribute it and/or modify it under
the same terms as the Perl 5 programming language system itself.

=cut



( run in 0.922 second using v1.01-cache-2.11-cpan-d7f47b0818f )