File Coverage

blib/lib/Mojolicious/Command/nopaste.pm
Criterion Covered Total %
statement 6 7 85.7
branch n/a
condition n/a
subroutine 2 3 66.6
pod 1 1 100.0
total 9 11 81.8


line stmt bran cond sub pod time code
1             package Mojolicious::Command::nopaste;
2 1     1   490 use Mojo::Base 'Mojolicious::Commands';
  1         2  
  1         9  
3 1     1   107271 use Mojolicious::Command::nopaste::Service;
  1         4  
  1         11  
4              
5             our $VERSION = '0.10';
6             $VERSION = eval $VERSION;
7              
8             has description => "Paste to your favorite pastebin sites.\n";
9              
10             has message => sub {
11             return shift->description . <
12              
13             These services are currently available:
14             EOF
15             };
16              
17             has hint => "\n" . $Mojolicious::Command::nopaste::Service::USAGE . <
18              
19             See '$0 nopaste help SERVICE' for more information on a specific service implementation.
20             EOF
21              
22             has namespaces => sub { ['Mojolicious::Command::nopaste::Service'] };
23              
24 0     0 1   sub help { shift->run(@_) }
25              
26             1;
27              
28             =head1 NAME
29              
30             Mojolicious::Command::nopaste - A clone of App::Nopaste using Mojolicious
31              
32             =head1 SYNOPSIS
33              
34             $ mojo nopaste pastie myfile.pl
35             $ cat myfile.pl | mojo nopaste shadowcat
36             $ mojo nopaste -p # contents pulled from clipboard
37              
38             =head1 DESCRIPTION
39              
40             This module is a clone of the venerable L using the L toolkit.
41             Nearly all of the functionality is mimicked.
42             Where possible the command-line system has been replicated, though the mechanism of
43             choosing the service differs due to the way the L system works.
44              
45             Files may be passed as arguments, read from STDIN or even read from the clipboard with the
46             L module.
47             For a list of available services run C or C.
48              
49             =head1 SEE ALSO
50              
51             =over
52              
53             =item L
54              
55             =item L
56              
57             =back
58              
59             =head1 SOURCE REPOSITORY
60              
61             L
62              
63             =head1 AUTHOR
64              
65             Joel Berger, Ejoel.a.berger@gmail.comE
66              
67             =head1 COPYRIGHT AND LICENSE
68              
69             Copyright (C) 2013 by Joel Berger
70              
71             This library is free software; you can redistribute it and/or modify
72             it under the same terms as Perl itself.