view release on metacpan or search on metacpan
inc/Module/AutoInstall.pm view on Meta::CPAN
my $cur = _load($mod);
if (_version_cmp ($cur, $arg) >= 0)
{
print "loaded. ($cur" . ( $arg ? " >= $arg" : '' ) . ")\n";
push @Existing, $mod => $arg;
$DisabledTests{$_} = 1 for map { glob($_) } @skiptests;
}
else {
if (not defined $cur) # indeed missing
{
print "missing." . ( $arg ? " (would need $arg)" : '' ) . "\n";
inc/Module/AutoInstall.pm view on Meta::CPAN
) =~ /^[Yy]/
)
)
{
push( @Missing, @required );
$DisabledTests{$_} = 1 for map { glob($_) } @skiptests;
}
elsif ( !$SkipInstall
and $default
and $mandatory
and
_prompt( qq{==> The module(s) are mandatory! Really skip?}, 'n', )
=~ /^[Nn]/ )
{
push( @Missing, @required );
$DisabledTests{$_} = 1 for map { glob($_) } @skiptests;
}
else {
$DisabledTests{$_} = 1 for map { glob($_) } @tests;
}
}
if ( @Missing and not( $CheckOnly or $UnderCPAN ) ) {
require Config;
inc/Module/AutoInstall.pm view on Meta::CPAN
}
$args{test}{TESTS} ||= 't/*.t';
$args{test}{TESTS} = join( ' ',
grep { !exists( $DisabledTests{$_} ) }
map { glob($_) } split( /\s+/, $args{test}{TESTS} ) );
my $missing = join( ',', @Missing );
my $config =
join( ',', UNIVERSAL::isa( $Config, 'HASH' ) ? %{$Config} : @{$Config} )
if $Config;
view all matches for this distribution
view release on metacpan or search on metacpan
* Add check to Makefile to abort in a Windows environment (neither i3 nor
unix sockets available)
0.05 2010-06-09
* use getpwuid() to resolve ~ in socket paths instead of glob()
0.04 2010-03-27
* use new default ipc-socket path, glob() path, bump version
0.03 2010-03-26
* fix MANIFEST
view all matches for this distribution
view release on metacpan or search on metacpan
},
name => 'AnyEvent-IRC-Server',
module_name => 'AnyEvent::IRC::Server',
script_files => [glob('script/*'), glob('bin/*')],
test_files => ((-d '.git' || $ENV{RELEASE_TESTING}) && -d 'xt') ? 't/ xt/' : 't/',
recursive_test_files => 1,
);
if (-d 'share') {
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install.pm view on Meta::CPAN
@exts = $self->{admin}->load_all_extensions;
}
my %seen;
foreach my $obj ( @exts ) {
while (my ($method, $glob) = each %{ref($obj) . '::'}) {
next unless $obj->can($method);
next if $method =~ /^_/;
next if $method eq uc($method);
$seen{$method}++;
}
view all matches for this distribution
view release on metacpan or search on metacpan
Makefile.PL view on Meta::CPAN
#regen_EXAMPLES();
(my $main_version)
= $content =~ m/ [^\n]* \$VERSION \s* = [^=] '([\d_.]+) [^\n]+ /gxms;
my @tests = map { glob $_ } 't/*.t', 't/*/*.t';
my %module = (
NAME => $module,
AUTHOR => q{Max Maischein <corion@cpan.org>},
VERSION_FROM => $main_file,
view all matches for this distribution
view release on metacpan or search on metacpan
name => 'AnyEvent-InMemoryCache',
module_name => 'AnyEvent::InMemoryCache',
allow_pureperl => 0,
script_files => [glob('script/*'), glob('bin/*')],
c_source => [qw()],
PL_files => {},
test_files => ((-d '.git' || $ENV{RELEASE_TESTING}) && -d 'xt') ? 't/ xt/' : 't/',
recursive_test_files => 1,
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install.pm view on Meta::CPAN
@exts = $self->{admin}->load_all_extensions;
}
my %seen;
foreach my $obj ( @exts ) {
while (my ($method, $glob) = each %{ref($obj) . '::'}) {
next unless $obj->can($method);
next if $method =~ /^_/;
next if $method eq uc($method);
$seen{$method}++;
}
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install.pm view on Meta::CPAN
@exts = $self->{admin}->load_all_extensions;
}
my %seen;
foreach my $obj ( @exts ) {
while (my ($method, $glob) = each %{ref($obj) . '::'}) {
next unless $obj->can($method);
next if $method =~ /^_/;
next if $method eq uc($method);
$seen{$method}++;
}
view all matches for this distribution
view release on metacpan or search on metacpan
name => 'AnyEvent-LeapMotion',
module_name => 'AnyEvent::LeapMotion',
allow_pureperl => 0,
script_files => [glob('script/*'), glob('bin/*')],
c_source => [qw()],
PL_files => {},
test_files => ((-d '.git' || $ENV{RELEASE_TESTING}) && -d 'xt') ? 't/ xt/' : 't/',
recursive_test_files => 1,
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install.pm view on Meta::CPAN
@exts = $self->{admin}->load_all_extensions;
}
my %seen;
foreach my $obj ( @exts ) {
while (my ($method, $glob) = each %{ref($obj) . '::'}) {
next unless $obj->can($method);
next if $method =~ /^_/;
next if $method eq uc($method);
$seen{$method}++;
}
view all matches for this distribution
view release on metacpan or search on metacpan
=item seed IDs - C<host:port>
Seed IDs are transport endpoint(s) (usually a hostname/IP address and a
TCP port) of nodes that should be used as seed nodes.
=item global nodes
An AEMP network needs a discovery service - nodes need to know how to
connect to other nodes they only know by name. In addition, AEMP offers a
distributed "group database", which maps group names to a list of strings
- for example, to register worker ports.
A network needs at least one global node to work, and allows every node to
be a global node.
Any node that loads the L<AnyEvent::MP::Global> module becomes a global
node and tries to keep connections to all other nodes. So while it can
make sense to make every node "global" in small networks, it usually makes
sense to only make seed nodes into global nodes in large networks (nodes
keep connections to seed nodes and global nodes, so making them the same
reduces overhead).
=back
=head1 VARIABLES/FUNCTIONS
The profile data is then gathered as follows:
First, all remaining key => value pairs (all of which are conveniently
undocumented at the moment) will be interpreted as configuration
data. Then they will be overwritten by any values specified in the global
default configuration (see the F<aemp> utility), then the chain of
profiles chosen by the profile name (and any C<parent> attributes).
That means that the values specified in the profile have highest priority
and the values specified directly via C<configure> have lowest priority,
Creates a new local port, and returns its ID. Semantically the same as
creating a port and calling C<rcv $port, $callback> on it.
The block will be called for every message received on the port, with the
global variable C<$SELF> set to the port ID. Runtime errors will cause the
port to be C<kil>ed. The message will be passed as-is, no extra argument
(i.e. no port ID) will be passed to the callback.
If you want to stop/destroy the port, simply C<kil> it:
Replaces the default callback on the specified port. There is no way to
remove the default callback: use C<sub { }> to disable it, or better
C<kil> the port when it is no longer needed.
The global C<$SELF> (exported by this module) contains C<$port> while
executing the callback. Runtime errors during callback execution will
result in the port being C<kil>ed.
The default callback receives all messages not matched by a more specific
C<tag> match.
=back
=head1 DISTRIBUTED DATABASE
AnyEvent::MP comes with a simple distributed database. The database will
be mirrored asynchronously on all global nodes. Other nodes bind to one
of the global nodes for their needs. Every node has a "local database"
which contains all the values that are set locally. All local databases
are merged together to form the global database, which can be queried.
The database structure is that of a two-level hash - the database hash
contains hashes which contain values, similarly to a perl hash of hashes,
i.e.:
The family must be alphanumeric, i.e. start with a letter and consist
of letters, digits, underscores and colons (C<[A-Za-z][A-Za-z0-9_:]*>,
pretty much like Perl module names.
As the family namespace is global, it is recommended to prefix family names
with the name of the application or module using it.
The subkeys must be non-empty strings, with no further restrictions.
The values should preferably be strings, but other perl scalars should
Strings can easily be printed, easily serialised etc. and need no special
procedures to be "valid".
And as a result, a port with just a default receiver consists of a single
code reference stored in a global hash - it can't become much cheaper.
=item Why favour JSON, why not a real serialising format such as Storable?
In fact, any AnyEvent::MP node will happily accept Storable as framing
format, but currently there is no way to make a node use Storable by
In AEMP 1.x, every node automatically loads the L<AnyEvent::MP::Global>
module, which in turn would create connections to all other nodes in the
network (helped by the seed nodes).
In version 2.x, global nodes still connect to all other global nodes, but
other nodes don't - now every node either is a global node itself, or
attaches itself to another global node.
If a node isn't a global node itself, then it attaches itself to one
of its seed nodes. If that seed node isn't a global node yet, it will
automatically be upgraded to a global node.
So in many cases, nothing needs to be changed - one just has to make sure
that all seed nodes are meshed together with the other seed nodes (as with
AEMP 1.x), and other nodes specify them as seed nodes. This is most easily
achieved by specifying the same set of seed nodes for all nodes in the
There are vague plans to implement some form of routing domains, which
might or might not bring back listener-less nodes, but don't count on it.
The fact that most connections are now optional somewhat mitigates this,
as a node can be effectively unreachable from the outside without any
problems, as long as it isn't a global node and only reaches out to other
nodes (as opposed to being contacted from other nodes).
=item $AnyEvent::MP::Kernel::WARN has gone.
AnyEvent has acquired a logging framework (L<AnyEvent::Log>), and AEMP now
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install.pm view on Meta::CPAN
@exts = $self->{admin}->load_all_extensions;
}
my %seen;
foreach my $obj ( @exts ) {
while (my ($method, $glob) = each %{ref($obj) . '::'}) {
next unless $obj->can($method);
next if $method =~ /^_/;
next if $method eq uc($method);
$seen{$method}++;
}
view all matches for this distribution
view release on metacpan or search on metacpan
$mpv->cmd (loadfile => $mpv->escape_binary ($videofile));
$quit->recv;
This example uses a global condvar C<$quit> to wait for the file to finish
playing. Also, most of the logic is now implement in event handlers.
The two events handlers we register are C<start-file>, which is emitted by
F<mpv> once it has loaded a new file, and C<end-file>, which signals the
end of a file (underscores are internally replaced by minus signs, so you
w.r.t. the video framerate.
If the file does not have a video part, it assumes it is an audio file and
sets a visualizer.
Also, a number of properties are not global, but per-file. At the moment,
this is C<audio-delay>, and the current audio/subtitle track, which it
sets, and also creates an observer. Again, this doesn'T use the observe
functionality of this module, but handles it itself, assigning obsevrer
ids 100+ to temporary/per-file observers.
Lastly, it sets some global (or per-youtube-uploader) parameters, such as
speed, and unpauses. Property changes are handled like other input events:
} elsif ($INPUT eq "mpv/property-change") {
my $prop = $INPUT_DATA->{name};
view all matches for this distribution
view release on metacpan or search on metacpan
misc/test-server view on Meta::CPAN
use warnings;
use strict;
use FindBin;
use Test::Harness;
my @files = @ARGV;
@files = glob($FindBin::Bin.'/t/*.t') unless (@files);
$ENV{ANYEVENT_MQTT_SERVER} = '127.0.0.1'
unless (exists $ENV{ANYEVENT_MQTT_SERVER});
runtests(@files);
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/AutoInstall.pm view on Meta::CPAN
my $cur = _version_of($mod);
if (_version_cmp ($cur, $arg) >= 0)
{
print "loaded. ($cur" . ( $arg ? " >= $arg" : '' ) . ")\n";
push @Existing, $mod => $arg;
$DisabledTests{$_} = 1 for map { glob($_) } @skiptests;
}
else {
if (not defined $cur) # indeed missing
{
print "missing." . ( $arg ? " (would need $arg)" : '' ) . "\n";
inc/Module/AutoInstall.pm view on Meta::CPAN
) =~ /^[Yy]/
)
)
{
push( @Missing, @required );
$DisabledTests{$_} = 1 for map { glob($_) } @skiptests;
}
elsif ( !$SkipInstall
and $default
and $mandatory
and
_prompt( qq{==> The module(s) are mandatory! Really skip?}, 'n', )
=~ /^[Nn]/ )
{
push( @Missing, @required );
$DisabledTests{$_} = 1 for map { glob($_) } @skiptests;
}
else {
$DisabledTests{$_} = 1 for map { glob($_) } @tests;
}
}
if ( @Missing and not( $CheckOnly or $UnderCPAN) ) {
require Config;
inc/Module/AutoInstall.pm view on Meta::CPAN
}
$args{test}{TESTS} ||= 't/*.t';
$args{test}{TESTS} = join( ' ',
grep { !exists( $DisabledTests{$_} ) }
map { glob($_) } split( /\s+/, $args{test}{TESTS} ) );
my $missing = join( ',', @Missing );
my $config =
join( ',', UNIVERSAL::isa( $Config, 'HASH' ) ? %{$Config} : @{$Config} )
if $Config;
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install.pm view on Meta::CPAN
@exts = $self->{admin}->load_all_extensions;
}
my %seen;
foreach my $obj ( @exts ) {
while (my ($method, $glob) = each %{ref($obj) . '::'}) {
next unless $obj->can($method);
next if $method =~ /^_/;
next if $method eq uc($method);
$seen{$method}++;
}
view all matches for this distribution
view release on metacpan or search on metacpan
lib/AnyEvent/Net/Amazon/S3.pm view on Meta::CPAN
aws_secret_access_key => $aws_secret_access_key,
retry => 1,
}
);
# a bucket is a globally-unique directory
# list all buckets that i own
my $response = $s3->buckets;
foreach my $bucket ( @{ $response->{buckets} } ) {
print "You have a bucket: " . $bucket->bucket . "\n";
}
view all matches for this distribution
view release on metacpan or search on metacpan
eg/benchmark.pl view on Meta::CPAN
@queue = shuffle @new_queue;
}
my $tests = {};
for my $file (glob q(Gauge/*.pm)) {
next if $file =~ /\bRole\b/x;
my $class = $file;
$class =~ s{/}{::}gx;
$class =~ s{\.pm$}{}x;
view all matches for this distribution
view release on metacpan or search on metacpan
examples/sftp-server-wrapper.pl view on Meta::CPAN
#!/usr/bin/perl
use strict;
use warnings;
exec qw(perl -Mlib::glob=/home/salva/g/perl/p5-*/lib
/home/salva/g/perl/p5-AnyEvent-PacketForwarder/examples/N-slave.pl
/usr/lib/openssh/sftp-server);
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install.pm view on Meta::CPAN
@exts = $self->{admin}->load_all_extensions;
}
my %seen;
foreach my $obj ( @exts ) {
while (my ($method, $glob) = each %{ref($obj) . '::'}) {
next unless $obj->can($method);
next if $method =~ /^_/;
next if $method eq uc($method);
$seen{$method}++;
}
view all matches for this distribution
view release on metacpan or search on metacpan
example/ex.pl view on Meta::CPAN
$cv = AE::cv;
# multi-server request with sub-callbacks to some data manipulation
# and may be to make another request to current server
# main request | server_1 select -> ... select end -> cb_server call -> subrequests to current server | wait both | global callback
# | server_2 select -> ... select end -> cb_server call -> subrequests to current server | subrequests |
$pool->selectall_arrayref(
query => 'SELECT val FROM ( SELECT 1 AS val ) tmp WHERE tmp.val = $1;',
args => [ 1 ],
view all matches for this distribution
view release on metacpan or search on metacpan
lib/AnyEvent/Pg/Pool.pm view on Meta::CPAN
$conninfo = { %$conninfo } if ref $conninfo;
my $size = delete $opts{size} // $default{size};
my $connection_retries = delete $opts{connection_retries} // $default{connection_retries};
my $connection_delay = delete $opts{connection_delay} // $default{connection_delay};
my $timeout = delete $opts{timeout} // $default{timeout};
my $global_timeout = delete $opts{global_timeout};
my $on_error = delete $opts{on_error} ;
my $on_connect_error = delete $opts{on_connect_error};
my $on_transient_error = delete $opts{on_transient_error};
# my $on_empty_queue = delete $opts{on_empty_queue};
my $pool = { conninfo => $conninfo,
lib/AnyEvent/Pg/Pool.pm view on Meta::CPAN
# on_empty_queue => $on_empty_queue,
timeout => $timeout,
max_conn_retries => $connection_retries,
conn_retries => 0,
conn_delay => $connection_delay,
global_timeout => $global_timeout,
conns => {},
current => {},
busy => {},
idle => {},
connecting => {},
lib/AnyEvent/Pg/Pool.pm view on Meta::CPAN
sub set {
my $pool = shift;
while (@_) {
my $k = shift;
my $v = shift // $default{$k};
if ($k eq 'global_timeout') {
if (defined (my $gt = shift)) {
$pool->{max_conn_time} += $gt - $pool->{global_timeout}
if defined $pool->{max_conn_time};
}
else {
delete $pool->{max_conn_time};
}
lib/AnyEvent/Pg/Pool.pm view on Meta::CPAN
# unless it is the only connection remaining. Effectively the
# module will keep going until all the connections become
# broken and no more connections can be established.
unless (keys(%{$pool->{conns}}) > 1) {
$pool->{conn_retries}++;
if ($pool->{global_timeout}) {
$pool->{max_conn_time} ||= $now + $pool->{global_timeout} - $pool->{conn_delay};
}
}
if ($pool->{conn_retries} <= $pool->{max_conn_retries}) {
if (not $pool->{max_conn_time} or $pool->{max_conn_time} >= $now) {
$debug and $debug & 8 and $pool->_debug("starting timer for delayed reconnection $pool->{conn_delay}s");
$pool->{delay_watcher} = AE::timer $pool->{conn_delay}, 0, weak_method_callback($pool, '_on_delayed_reconnect');
return
}
$debug and $debug & 8 and $pool->_debug("global_timeout expired");
}
# giving up!
$debug and $debug & 8 and $pool->_debug("it has been impossible to connect to the database, giving up!!!");
$pool->{dead} = 1;
lib/AnyEvent/Pg/Pool.pm view on Meta::CPAN
=item timeout => $seconds
When some active connection does not report activity for the given
number of seconds, it is considered dead and closed.
=item global_timeout => $seconds
When all the connections to the database become broken and it is not
possible to establish a new connection for the given time period the
pool is considered dead and the C<on_error> callback will be called.
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/Install.pm view on Meta::CPAN
@exts = $self->{admin}->load_all_extensions;
}
my %seen;
foreach my $obj ( @exts ) {
while (my ($method, $glob) = each %{ref($obj) . '::'}) {
next unless $obj->can($method);
next if $method =~ /^_/;
next if $method eq uc($method);
$seen{$method}++;
}
view all matches for this distribution
view release on metacpan or search on metacpan
name => 'AnyEvent-Plackup',
module_name => 'AnyEvent::Plackup',
allow_pureperl => 0,
script_files => [glob('script/*'), glob('bin/*')],
c_source => [qw()],
PL_files => {},
test_files => ((-d '.git' || $ENV{RELEASE_TESTING}) && -d 'xt') ? 't/ xt/' : 't/',
recursive_test_files => 1,
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/AutoInstall.pm view on Meta::CPAN
my $cur = _load($mod);
if (_version_cmp ($cur, $arg) >= 0)
{
print "loaded. ($cur" . ( $arg ? " >= $arg" : '' ) . ")\n";
push @Existing, $mod => $arg;
$DisabledTests{$_} = 1 for map { glob($_) } @skiptests;
}
else {
if (not defined $cur) # indeed missing
{
print "missing." . ( $arg ? " (would need $arg)" : '' ) . "\n";
inc/Module/AutoInstall.pm view on Meta::CPAN
) =~ /^[Yy]/
)
)
{
push( @Missing, @required );
$DisabledTests{$_} = 1 for map { glob($_) } @skiptests;
}
elsif ( !$SkipInstall
and $default
and $mandatory
and
_prompt( qq{==> The module(s) are mandatory! Really skip?}, 'n', )
=~ /^[Nn]/ )
{
push( @Missing, @required );
$DisabledTests{$_} = 1 for map { glob($_) } @skiptests;
}
else {
$DisabledTests{$_} = 1 for map { glob($_) } @tests;
}
}
if ( @Missing and not( $CheckOnly or $UnderCPAN ) ) {
require Config;
inc/Module/AutoInstall.pm view on Meta::CPAN
}
$args{test}{TESTS} ||= 't/*.t';
$args{test}{TESTS} = join( ' ',
grep { !exists( $DisabledTests{$_} ) }
map { glob($_) } split( /\s+/, $args{test}{TESTS} ) );
my $missing = join( ',', @Missing );
my $config =
join( ',', UNIVERSAL::isa( $Config, 'HASH' ) ? %{$Config} : @{$Config} )
if $Config;
view all matches for this distribution
view release on metacpan or search on metacpan
Porttracker/protocol.pod view on Meta::CPAN
> [ 1, "poller_subnet_list_modify", "64424509930",[["1.1.1.1",32,1000,1,2],
["10.1.1.1",32,1000,0,0]], [["192.168.0.0", 16, 1200, 1,2]] ]
< [1, 1]
=item "global_settings" - list global settings
This request returns all global settings or specific settings.
> [<id>, "global_settings"]
< [<id>, 1, [ [<property>, <value>]... ]]
The reply contains an array with all configured properties and values. Each property
and value will be in textual form.
Porttracker/protocol.pod view on Meta::CPAN
session_timeout, domain, smtp_server, max_history_length,
smtp_user, max_log_length
Example:
> [1, "global_settings"]
< [1,1,[["domain",""],["smtp_server",""],
["max_history_length","0"],["smtp_user",""]]]
> [1, "global_settings", ["session_timeout"]]
< [1,1,[["session_timeout","86400"]]]
=item "global_settings_modify" - modify global settings
This request modifies global settings. Each property modified with a new value given.
> [<id>, "global_settings_modify", [ [<property>, <value>]... ]]
< [<id>, 1]
one array for each property and value pair. Properties and values should be in
textual format.
Porttracker/protocol.pod view on Meta::CPAN
session_timeout, domain, smtp_server, max_history_length,
smtp_user, max_log_length
Example:
> [1, "global_settings_modify", [["snmp_parallel_requests", "15"]]]
< [1, 1]
=item "advanced_settings" - list advanced settings
This request returns all advanced settings or specific settings.
view all matches for this distribution
view release on metacpan or search on metacpan
lib/AnyEvent/Process.pm view on Meta::CPAN
}
push @fh_table, [$handle, $fh];
} elsif ($args->[0] eq 'decorate') {
my $out = $args->[3];
unless (defined $out or ref $out eq 'GLOB') {
croak "Third argument of decorate must be a glob reference";
}
my ($my_fh, $child_fh) = portable_pipe;
unless (defined $my_fh && defined $child_fh) {
croak "Creating pipe failed: $!";
lib/AnyEvent/Process.pm view on Meta::CPAN
=over 4
=item pipe
Opens an unidirectional pipe or a bidirectional socket (depends on the DIRECTION)
between the current and the new process. ARGS can be a glob reference, then the
second end of the pipe or socket pair is connected to it, or C<handle =E<gt>
[handle_args...]>, where handle_args are an argument passed to the
L<AnyEvent::Handle|AnyEvent::Handle> constructor, which will be connected to the
second end of the pipe or socket. In the a case handle_args is in the form of
C<method =E<gt> [method_args...]> and method is AnyEvent::Handle method, then
lib/AnyEvent/Process.pm view on Meta::CPAN
0 => ['open', '<', '/dev/null']
=item decorate
Decorate every line written to the HANDLE by the child. The DIRECTION must be
C<E<gt>>. ARGS are in the form C<DECORATOR, OUTPUT>. OUTPUT is a glob reference
and specifies a file handle, into which decorated lines are written. Decorator is
a string or a code reference. If the decorator is a string, it is prepended to
every line written by the started process. If the DECORATOR is a code reference,
it is called for each line written to the HANDLE with that line as its argument
and its return value is written to the OUTPUT.
view all matches for this distribution
view release on metacpan or search on metacpan
lib/AnyEvent/ProcessPool.pm view on Meta::CPAN
}
}
}
sub DESTROY {
my ($self, $global) = @_;
if ($self) {
# Unblock watchers for any remaining pending tasks
if (ref $self->{pending}) {
foreach my $cv (values %{$self->{pending}}) {
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/AutoInstall.pm view on Meta::CPAN
my $cur = _load($mod);
if (_version_cmp ($cur, $arg) >= 0)
{
print "loaded. ($cur" . ( $arg ? " >= $arg" : '' ) . ")\n";
push @Existing, $mod => $arg;
$DisabledTests{$_} = 1 for map { glob($_) } @skiptests;
}
else {
if (not defined $cur) # indeed missing
{
print "missing." . ( $arg ? " (would need $arg)" : '' ) . "\n";
inc/Module/AutoInstall.pm view on Meta::CPAN
) =~ /^[Yy]/
)
)
{
push( @Missing, @required );
$DisabledTests{$_} = 1 for map { glob($_) } @skiptests;
}
elsif ( !$SkipInstall
and $default
and $mandatory
and
_prompt( qq{==> The module(s) are mandatory! Really skip?}, 'n', )
=~ /^[Nn]/ )
{
push( @Missing, @required );
$DisabledTests{$_} = 1 for map { glob($_) } @skiptests;
}
else {
$DisabledTests{$_} = 1 for map { glob($_) } @tests;
}
}
if ( @Missing and not( $CheckOnly or $UnderCPAN ) ) {
require Config;
inc/Module/AutoInstall.pm view on Meta::CPAN
}
$args{test}{TESTS} ||= 't/*.t';
$args{test}{TESTS} = join( ' ',
grep { !exists( $DisabledTests{$_} ) }
map { glob($_) } split( /\s+/, $args{test}{TESTS} ) );
my $missing = join( ',', @Missing );
my $config =
join( ',', UNIVERSAL::isa( $Config, 'HASH' ) ? %{$Config} : @{$Config} )
if $Config;
view all matches for this distribution
view release on metacpan or search on metacpan
inc/Module/AutoInstall.pm view on Meta::CPAN
my $cur = _load($mod);
if (_version_cmp ($cur, $arg) >= 0)
{
print "loaded. ($cur" . ( $arg ? " >= $arg" : '' ) . ")\n";
push @Existing, $mod => $arg;
$DisabledTests{$_} = 1 for map { glob($_) } @skiptests;
}
else {
if (not defined $cur) # indeed missing
{
print "missing." . ( $arg ? " (would need $arg)" : '' ) . "\n";
inc/Module/AutoInstall.pm view on Meta::CPAN
) =~ /^[Yy]/
)
)
{
push( @Missing, @required );
$DisabledTests{$_} = 1 for map { glob($_) } @skiptests;
}
elsif ( !$SkipInstall
and $default
and $mandatory
and
_prompt( qq{==> The module(s) are mandatory! Really skip?}, 'n', )
=~ /^[Nn]/ )
{
push( @Missing, @required );
$DisabledTests{$_} = 1 for map { glob($_) } @skiptests;
}
else {
$DisabledTests{$_} = 1 for map { glob($_) } @tests;
}
}
if ( @Missing and not( $CheckOnly or $UnderCPAN ) ) {
require Config;
inc/Module/AutoInstall.pm view on Meta::CPAN
}
$args{test}{TESTS} ||= 't/*.t';
$args{test}{TESTS} = join( ' ',
grep { !exists( $DisabledTests{$_} ) }
map { glob($_) } split( /\s+/, $args{test}{TESTS} ) );
my $missing = join( ',', @Missing );
my $config =
join( ',', UNIVERSAL::isa( $Config, 'HASH' ) ? %{$Config} : @{$Config} )
if $Config;
view all matches for this distribution