Result:
found more than 489 distributions - search limited to the first 2001 files matching your query ( run in 1.149 )


Acme-SList-XSLT

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN


  [DOCUMENTATION]

  - Add a .gitignore file

  - Changelog dates are better written as YYYY.MM.DD and probably ordered in
    the other, descending, direction
    Remark: I have decided to follow the ISO 8601 standard at
    http://www.w3.org/TR/NOTE-datetime

  - Just use a Makefile.PL and not a Build.PL the latter does not have any

 view all matches for this distribution


Acme-STEVEB

 view release on metacpan or  search on metacpan

MANIFEST.SKIP  view on Meta::CPAN

.travis.yml$
.iml$
examples/
build/
^\w+.list$
.bblog$
.base$
BB-Pass/
BB-Fail/
cover_db/
scrap\.pl

 view all matches for this distribution


Acme-Schlong

 view release on metacpan or  search on metacpan

lib/Acme/Schlong.pm  view on Meta::CPAN

    has username_length => ( is => 'ro', isa => Int,  lazy_build => 1, documentation => q{self explanatory} );
    has shell           => ( is => 'ro', isa => Str,  lazy_build => 1, documentation => q{self explanatory} );
    has harddrive_size  => ( is => 'ro', isa => Int,  lazy_build => 1, documentation => q{self explanatory} );
    has harddrive_used  => ( is => 'ro', isa => Int,  lazy_build => 1, documentation => q{self explanatory} );
    has uptime          => ( is => 'ro', isa => Any,  lazy_build => 1, documentation => q{self explanatory} );
    has users           => ( is => 'ro', isa => Any,  lazy_build => 1, documentation => q{The number of users logged in on the system} );
    has cores           => ( is => 'ro', isa => Any,  lazy_build => 1, documentation => q{The Number of cores of this machine} );
    has using_multiplex => ( is => 'ro', isa => Bool, lazy_build => 1, documentation => q{using screen or tmux});
    has using_byobu     => ( is => 'ro', isa => Bool, lazy_build => 1, documentation => q{using byobu as multiplexer frontend!} );
    has using_tmux      => ( is => 'ro', isa => Bool, lazy_build => 1, documentation => q{using tmux as multiplexer} );
    has using_screen    => ( is => 'ro', isa => Bool, lazy_build => 1, documentation => q{using screen as multiplexer} );

lib/Acme/Schlong.pm  view on Meta::CPAN


Find good ways to calculate the following:

=back

   * number of users logged in on the system (one user with 9 shells is 1 user.)
   * harddisk size
   * memory used
   * swap used
   * harddisk free space
   * uptime in minutes

 view all matches for this distribution


Acme-Scurvy-Whoreson-BilgeRat-Backend-insultserver

 view release on metacpan or  search on metacpan

lib/Acme/Scurvy/Whoreson/BilgeRat/Backend/insultserver.pm  view on Meta::CPAN

adj currish milk-livered surly mammering ill-borne beef-witted tickle-brained
adj half-faced headless wayward rump-fed onion-eyed beslubbering villainous
adj lewd-minded cockered full-gorged rude-snouted crook-pated pribbling
adj dread-bolted fool-born puny fawning sheep-biting dankish goatish
adj weather-bitten knotty-pated malt-wormy saucyspleened motley-mind
adj it-fowling vassal-willed loggerheaded clapper-clawed frothy ruttish
adj clouted common-kissing pignutted folly-fallen plume-plucked flap-mouthed
adj swag-bellied dizzy-eyed gorbellied weedy reeky measled spur-galled mangled
adj impertinent bootless toad-spotted hasty-witted horn-beat yeasty
adj imp-bladdereddle-headed boil-brained tottering hedge-born hugger-muggered 
adj elf-skinned

 view all matches for this distribution


Acme-Shining

 view release on metacpan or  search on metacpan

lib/Acme/Shining.pm  view on Meta::CPAN

If your Modified Version has been derived from a Modified Version made
by someone other than you, you are nevertheless required to ensure that
your Modified Version complies with the requirements of this license.

This license does not grant you the right to use any trademark, service
mark, tradename, or logo of the Copyright Holder.

This license includes the non-exclusive, worldwide, free-of-charge
patent license to make, have made, use, offer to sell, sell, import and
otherwise transfer the Package with respect to any patent claims
licensable by the Copyright Holder that are necessarily infringed by the

 view all matches for this distribution


Acme-Shukugawa-Atom

 view release on metacpan or  search on metacpan

inc/Module/Install/Fetch.pm  view on Meta::CPAN

        LWP::Simple::mirror($args{url}, $file);
    }
    elsif (eval { require Net::FTP; 1 }) { eval {
        # use Net::FTP to get past firewall
        my $ftp = Net::FTP->new($host, Passive => 1, Timeout => 600);
        $ftp->login("anonymous", 'anonymous@example.com');
        $ftp->cwd($path);
        $ftp->binary;
        $ftp->get($file) or (warn("$!\n"), return);
        $ftp->quit;
    } }

inc/Module/Install/Fetch.pm  view on Meta::CPAN

        unless ($fh->open("|$ftp -n")) {
            warn "Couldn't open ftp: $!\n";
            chdir $dir; return;
        }

        my @dialog = split(/\n/, <<"END_FTP");
open $host
user anonymous anonymous\@example.com
cd $path
binary
get $file $file
quit
END_FTP
        foreach (@dialog) { $fh->print("$_\n") }
        $fh->close;
    } }
    else {
        warn "No working 'ftp' program available!\n";
        chdir $dir; return;

 view all matches for this distribution


Acme-Sneeze-JP

 view release on metacpan or  search on metacpan

inc/Module/Install/Fetch.pm  view on Meta::CPAN

        LWP::Simple::mirror($args{url}, $file);
    }
    elsif (eval { require Net::FTP; 1 }) { eval {
        # use Net::FTP to get past firewall
        my $ftp = Net::FTP->new($host, Passive => 1, Timeout => 600);
        $ftp->login("anonymous", 'anonymous@example.com');
        $ftp->cwd($path);
        $ftp->binary;
        $ftp->get($file) or (warn("$!\n"), return);
        $ftp->quit;
    } }

inc/Module/Install/Fetch.pm  view on Meta::CPAN

        unless ($fh->open("|$ftp -n")) {
            warn "Couldn't open ftp: $!\n";
            chdir $dir; return;
        }

        my @dialog = split(/\n/, <<"END_FTP");
open $host
user anonymous anonymous\@example.com
cd $path
binary
get $file $file
quit
END_FTP
        foreach (@dialog) { $fh->print("$_\n") }
        $fh->close;
    } }
    else {
        warn "No working 'ftp' program available!\n";
        chdir $dir; return;

 view all matches for this distribution


Acme-Sort-Sleep

 view release on metacpan or  search on metacpan

local/lib/perl5/Future.pm  view on Meta::CPAN

                                       # socket
   ->fail( $message, resolve => ... )  # a resolver (likely DNS) failure
                                       # to resolve a hostname

By following this convention, a module remains consistent with other
C<Future>-based modules, and makes it easy for program logic to gracefully
handle and manage failures by use of the C<catch> method.

=head2 SUBCLASSING

This class easily supports being subclassed to provide extra behavior, such as

local/lib/perl5/Future.pm  view on Meta::CPAN


I<Since version 0.09.>

A convenient wrapper around C<fail>. If the exception is a non-reference that
does not end in a linefeed, its value will be extended by the file and line
number of the caller, similar to the logic that C<die> uses.

Returns the C<$future>.

=cut

local/lib/perl5/Future.pm  view on Meta::CPAN

This method is invoked internally by various methods that are about to save a
callback CODE reference supplied by the user, to be invoked later. The default
implementation simply returns the callback agument as-is; the method is
provided to allow users to provide extra behaviour. This can be done by
applying a method modifier of the C<around> kind, so in effect add a chain of
wrappers. Each wrapper can then perform its own wrapping logic of the
callback. C<$operation_name> is a string giving the reason for which the
callback is being saved; currently one of C<on_ready>, C<on_done>, C<on_fail>
or C<sequence>; the latter being used for all the sequence-returning methods.

This method is intentionally invoked only for CODE references that are being

local/lib/perl5/Future.pm  view on Meta::CPAN

can provide some amount of context save and restore, to return the operating
environment for the callback back to what it was at the time it was saved.

For example, the following wrapper saves the value of a package variable at
the time the callback was saved, and restores that value at invocation time
later on. This could be useful for preserving context during logging in a
Future-based program.

 our $LOGGING_CTX;

 no warnings 'redefine';

 my $orig = Future->can( "wrap_cb" );
 *Future::wrap_cb = sub {
    my $cb = $orig->( @_ );

    my $saved_logging_ctx = $LOGGING_CTX;

    return sub {
       local $LOGGING_CTX = $saved_logging_ctx;
       $cb->( @_ );
    };
 };

At this point, any code deferred into a C<Future> by any of its callbacks will

local/lib/perl5/Future.pm  view on Meta::CPAN


In the C<then>-style case it is likely that this situation should be treated
as if C<$f1> had failed, perhaps with some special message. The C<else>-style
case is more complex, because it may be that the entire operation should still
fail, or it may be that the cancellation of C<$f1> should again be treated
simply as a special kind of failure, and the C<else> logic run as normal.

To be specific; in each case it is unclear what happens if the first future is
cancelled, while the second one is still waiting on it. The semantics for
"normal" top-down cancellation of C<$f2> and how it affects C<$f1> are already
clear and defined.

local/lib/perl5/Future.pm  view on Meta::CPAN

solve this question, though that itself is further complicated by the
C<on_ready> handler and its variants.

It may simply be that a comprehensive useful set of cancellation semantics
can't be universally provided to cover all cases; and that some use-cases at
least would require the application logic to give extra information to its
C<Future> objects on how they should wire up the cancel propagation logic.

Both of these cancellation issues are still under active design consideration;
see the discussion on RT96685 for more information
(L<https://rt.cpan.org/Ticket/Display.html?id=96685>).

local/lib/perl5/Future.pm  view on Meta::CPAN


=item *

"Futures advent calendar 2013"

L<http://leonerds-code.blogspot.co.uk/2013/12/futures-advent-day-1.html>

=back

=cut

 view all matches for this distribution


Acme-Spinodal-Utils

 view release on metacpan or  search on metacpan

lib/Acme/Spinodal/Utils.pm  view on Meta::CPAN

If your Modified Version has been derived from a Modified Version made
by someone other than you, you are nevertheless required to ensure that
your Modified Version complies with the requirements of this license.

This license does not grant you the right to use any trademark, service
mark, tradename, or logo of the Copyright Holder.

This license includes the non-exclusive, worldwide, free-of-charge
patent license to make, have made, use, offer to sell, sell, import and
otherwise transfer the Package with respect to any patent claims
licensable by the Copyright Holder that are necessarily infringed by the

 view all matches for this distribution


Acme-Spork

 view release on metacpan or  search on metacpan

lib/Acme/Spork.pm  view on Meta::CPAN


    print 1;
    spork( 
        sub { 
            sleep 5;
            open my $log_fh, '>>', 'spork.log', or die "spork.log open failed: $!";
            print {$log_fh} "I am spork hear me spoon\n"; 
            close $log_fh;
        },
    ) or die qq{Couldn't fork for spork: $!};
    print 2;

This prints out "12" immediately and is done running, now if you tail -f spork.log you'll see "I am spork hear me spoon\n" get written to it 4 or 5 seconds later by the spork()ed process :)

spork() returns the PID of the spork()ed process so you can keep track of them and do what you need with it.

If it returns false then fork failed so you can:

lib/Acme/Spork.pm  view on Meta::CPAN


    # and handle requests as a server:
    while(<$incoming_requests>) {
        my $req_pid = spork(\&handle_request($_));
        if($req_pid) {
            spork(\&log_request($_), $req_pid) 
                or warn "Could not spork log request $req_pid: $!";
        }
        else {
            warn "Could not spork request: $!";
        }
    }

 view all matches for this distribution


Acme-Sterling

 view release on metacpan or  search on metacpan

dist.ini  view on Meta::CPAN

exclude_filename = LICENSE
exclude_filename = Makefile.PL
[PkgVersion]
[AutoPrereqs]
[GithubMeta]
[ChangelogFromGit]
[MetaYAML]
[MetaJSON]
[MakeMaker]
[ModuleBuild]
[ManifestSkip]

 view all matches for this distribution


Acme-String-Trim

 view release on metacpan or  search on metacpan

docs/SubmittingPatches.pod  view on Meta::CPAN


=head2 Commits:

=over 4

=item * make commits of logical units

=item * check for unnecessary whitespace with "git diff --check" before committing

=item * do not check in commented out code or unneeded files

docs/SubmittingPatches.pod  view on Meta::CPAN

patches for discussion. Before the final merge, you may have to wait until
some of the dependent topics graduate to 'master', and rebase your work.

=back

To find the tip of a topic branch, run "git log --first-parent
master..pu" and look for the merge commit. The second parent of this
commit is the tip of the topic branch.

=head2 (1) Make separate commits for logically separate changes.

Unless your patch is really trivial, you should not be sending
out a patch that was generated between your working tree and
your commit head.  Instead, always make a commit with complete
commit message and generate a series of patches from your

docs/SubmittingPatches.pod  view on Meta::CPAN

not a text/plain, it's something else.

Unless your patch is a very trivial and an obviously correct one,
first send it with "To:" set to the RT email (or mailing list), with "cc:"
listing people who are involved in the area you are touching (the output from
"git blame $path" and "git shortlog --no-merges $path" would help to
identify them), to solicit comments and reviews.  After the list
reached a consensus that it is a good idea to apply the patch, re-send
it with "To:" set to the maintainer and optionally "cc:" the list for
inclusion.  Do not forget to add trailers such as "Acked-by:",
"Reviewed-by:" and "Tested-by:" after your "Signed-off-by:" line as

docs/SubmittingPatches.pod  view on Meta::CPAN


E<10>
The people who may need to know are the ones whose
code you are butchering.  These people happen to be the ones who are most
likely to be knowledgeable enough to help you, but they have no obligation to
help you (i.e. you ask for help, don't demand).  "git log -p --
$area_you_are_modifying" would help you find out who they are.

=item 2. You get comments and suggestions for improvements.  You may even
get them in a "on top of your change" patch form.

 view all matches for this distribution


Acme-StringFormat

 view release on metacpan or  search on metacpan

inc/Module/Install/Fetch.pm  view on Meta::CPAN

        LWP::Simple::mirror($args{url}, $file);
    }
    elsif (eval { require Net::FTP; 1 }) { eval {
        # use Net::FTP to get past firewall
        my $ftp = Net::FTP->new($host, Passive => 1, Timeout => 600);
        $ftp->login("anonymous", 'anonymous@example.com');
        $ftp->cwd($path);
        $ftp->binary;
        $ftp->get($file) or (warn("$!\n"), return);
        $ftp->quit;
    } }

inc/Module/Install/Fetch.pm  view on Meta::CPAN

        unless ($fh->open("|$ftp -n")) {
            warn "Couldn't open ftp: $!\n";
            chdir $dir; return;
        }

        my @dialog = split(/\n/, <<"END_FTP");
open $host
user anonymous anonymous\@example.com
cd $path
binary
get $file $file
quit
END_FTP
        foreach (@dialog) { $fh->print("$_\n") }
        $fh->close;
    } }
    else {
        warn "No working 'ftp' program available!\n";
        chdir $dir; return;

 view all matches for this distribution


Acme-Study-BLACKJ

 view release on metacpan or  search on metacpan

lib/Acme/Study/BLACKJ.pm  view on Meta::CPAN

If your Modified Version has been derived from a Modified Version made
by someone other than you, you are nevertheless required to ensure that
your Modified Version complies with the requirements of this license.

This license does not grant you the right to use any trademark, service
mark, tradename, or logo of the Copyright Holder.

This license includes the non-exclusive, worldwide, free-of-charge
patent license to make, have made, use, offer to sell, sell, import and
otherwise transfer the Package with respect to any patent claims
licensable by the Copyright Holder that are necessarily infringed by the

 view all matches for this distribution


Acme-Sub-Parms

 view release on metacpan or  search on metacpan

lib/Acme/Sub/Parms.pod  view on Meta::CPAN

This is a powerful, but simultaneously very dangerous feature. Use
this ability with caution. 

The callback must return either a true or a false value (not the
literal words 'true' or 'false' but something that evaluates to
a true or false logical value) and a string with an error message
(if a false value was returned.)

Callback function example:

 # Checking if the field value is an integer

 view all matches for this distribution


Acme-SuperCollider-Programming

 view release on metacpan or  search on metacpan

inc/Module/Install/Fetch.pm  view on Meta::CPAN

        LWP::Simple::mirror($args{url}, $file);
    }
    elsif (eval { require Net::FTP; 1 }) { eval {
        # use Net::FTP to get past firewall
        my $ftp = Net::FTP->new($host, Passive => 1, Timeout => 600);
        $ftp->login("anonymous", 'anonymous@example.com');
        $ftp->cwd($path);
        $ftp->binary;
        $ftp->get($file) or (warn("$!\n"), return);
        $ftp->quit;
    } }

inc/Module/Install/Fetch.pm  view on Meta::CPAN

        unless ($fh->open("|$ftp -n")) {
            warn "Couldn't open ftp: $!\n";
            chdir $dir; return;
        }

        my @dialog = split(/\n/, <<"END_FTP");
open $host
user anonymous anonymous\@example.com
cd $path
binary
get $file $file
quit
END_FTP
        foreach (@dialog) { $fh->print("$_\n") }
        $fh->close;
    } }
    else {
        warn "No working 'ftp' program available!\n";
        chdir $dir; return;

 view all matches for this distribution


Acme-TLDR

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN

Changelog for Acme-TLDR

0.004 2014-07-07T15:27:02
 - Use both Module::CoreList & ExtUtils::Installed as modules source
   (Stanislaw Pusep)

 view all matches for this distribution


Acme-TaintTest

 view release on metacpan or  search on metacpan

MANIFEST  view on Meta::CPAN

LICENSE
MANIFEST
Makefile.PL
README.md
lib/Acme/TaintTest.pm
log/dummy
t/a1.t
t/a2.t
t/README
t/testrules.yml
t/log/dummy
META.yml                                 Module YAML meta-data (added by MakeMaker)
META.json                                Module JSON meta-data (added by MakeMaker)

 view all matches for this distribution


Acme-Terror-AU

 view release on metacpan or  search on metacpan

inc/Module/Install/Fetch.pm  view on Meta::CPAN

        LWP::Simple::mirror($args{url}, $file);
    }
    elsif (eval { require Net::FTP; 1 }) { eval {
        # use Net::FTP to get past firewall
        my $ftp = Net::FTP->new($host, Passive => 1, Timeout => 600);
        $ftp->login("anonymous", 'anonymous@example.com');
        $ftp->cwd($path);
        $ftp->binary;
        $ftp->get($file) or (warn("$!\n"), return);
        $ftp->quit;
    } }

inc/Module/Install/Fetch.pm  view on Meta::CPAN

        unless ($fh->open("|$ftp -n")) {
            warn "Couldn't open ftp: $!\n";
            chdir $dir; return;
        }

        my @dialog = split(/\n/, <<"END_FTP");
open $host
user anonymous anonymous\@example.com
cd $path
binary
get $file $file
quit
END_FTP
        foreach (@dialog) { $fh->print("$_\n") }
        $fh->close;
    } }
    else {
        warn "No working 'ftp' program available!\n";
        chdir $dir; return;

 view all matches for this distribution


Acme-Test-DROLSKY

 view release on metacpan or  search on metacpan

LICENSE  view on Meta::CPAN

Version made by someone other than you, you are nevertheless required
to ensure that your Modified Version complies with the requirements of
this license.

(12)  This license does not grant you the right to use any trademark,
service mark, tradename, or logo of the Copyright Holder.

(13)  This license includes the non-exclusive, worldwide,
free-of-charge patent license to make, have made, use, offer to sell,
sell, import and otherwise transfer the Package with respect to any
patent claims licensable by the Copyright Holder that are necessarily

 view all matches for this distribution


Acme-Test-LogicalEquivalence

 view release on metacpan or  search on metacpan

lib/Acme/Test/LogicalEquivalence.pm  view on Meta::CPAN

package Acme::Test::LogicalEquivalence;
# ABSTRACT: Test if expressions are logically equivalent
# KEYWORDS: test logic

use 5.008;
use warnings;
use strict;

lib/Acme/Test/LogicalEquivalence.pm  view on Meta::CPAN


use Exporter qw(import);
use Test::More;
use namespace::clean -except => [qw(import)];

our @EXPORT_OK = qw(is_logically_equivalent);


sub is_logically_equivalent {
    my $numvars = shift;
    my $sub1 = shift;
    my $sub2 = shift;

    my $equivalence = 1;

lib/Acme/Test/LogicalEquivalence.pm  view on Meta::CPAN


=encoding UTF-8

=head1 NAME

Acme::Test::LogicalEquivalence - Test if expressions are logically equivalent

=head1 VERSION

version 0.001

=head1 SYNOPSIS

    use Test::More;
    use Acme::Test::LogicalEquivalence qw(is_logically_equivalent);

    # test two expressions with 2 variables using the special vars $a and $b
    is_logically_equivalent(2, sub { $a && $b }, sub { $b && $a });

    # same as above
    is_logically_equivalent(2, sub { $_[0] && $_[1] }, sub { $_[1] && $_[0] });

    # you can do as many vars as you like
    is_logically_equivalent(3, sub { $_[0] || ($_[1] && $_[2]) },
                               sub { ($_[0] || $_[1]) && ($_[0] || $_[2]) });

    done_testing;

=head1 DESCRIPTION

Some expressions are "logically equivalent" to other expressions, but it may not be easy to tell if
one or both of the expressions are reasonably complicated. Or maybe you're like many other people
and are too lazy to go through the effort... Either way, why not let your computer prove logical
equivalence for you?

=head1 FUNCTIONS

=head2 is_logically_equivalent

Test logical equivalence of two subroutines.

    my $is_equivalent = is_logically_equivalent($numvars, &sub1, &sub2);

This will execute both of the subroutines one or more times (depending on how many variables you
specify) with different inputs. The subroutines shall be considered logically equivalent if, for all
combinations of inputs, they both return the same thing.

Returns true if the subroutines are logically equivalent, false otherwise.

=head1 SEE ALSO

=over 4

=item *

What is logical equivalence? Start here: L<https://en.wikipedia.org/wiki/Logical_equivalence>

=back

=head1 AUTHOR

 view all matches for this distribution


Acme-TestDist-Cpp-EUMM-EUCppGuess

 view release on metacpan or  search on metacpan

ppport.h  view on Meta::CPAN


The name and version of the module you were trying to build.

=item 4.

A full log of the build that failed.

=item 5.

Any other information that you think could be relevant.

ppport.h  view on Meta::CPAN

memEQs|5.009005||p
memEQ|5.004000||p
memNEs|5.009005||p
memNE|5.004000||p
mem_collxfrm|||
mem_log_common|||n
mess_alloc|||
mess_nocontext|||vn
mess_sv||5.013001|
mess||5.006000|v
mfree||5.007002|n

ppport.h  view on Meta::CPAN

newXS||5.006000|
new_collate||5.006000|
new_constant|||
new_ctype||5.006000|
new_he|||
new_logop|||
new_numeric||5.006000|
new_stackinfo||5.005000|
new_version||5.009000|
new_warnings_bitfield|||
next_symbol|||

ppport.h  view on Meta::CPAN

whichsig|||
win32_croak_not_implemented|||n
with_queued_errors|||
wrap_op_checker||5.015008|
write_to_stderr|||
xs_boot_epilog|||
xs_handshake|||vn
xs_version_bootcheck|||
yyerror_pvn|||
yyerror_pv|||
yyerror|||

 view all matches for this distribution


Acme-Testing-Permissions

 view release on metacpan or  search on metacpan

dist.ini  view on Meta::CPAN


; git
[Git::Check]
[Git::Commit]
commit_msg  = Changes for version %v
changelog   = Changes

[Git::Tag]
tag_format  = v%v
tag_message = %N v%v

 view all matches for this distribution


Acme-Testing

 view release on metacpan or  search on metacpan

inc/Module/Install/Fetch.pm  view on Meta::CPAN

        LWP::Simple::mirror($args{url}, $file);
    }
    elsif (eval { require Net::FTP; 1 }) { eval {
        # use Net::FTP to get past firewall
        my $ftp = Net::FTP->new($host, Passive => 1, Timeout => 600);
        $ftp->login("anonymous", 'anonymous@example.com');
        $ftp->cwd($path);
        $ftp->binary;
        $ftp->get($file) or (warn("$!\n"), return);
        $ftp->quit;
    } }

inc/Module/Install/Fetch.pm  view on Meta::CPAN

        unless ($fh->open("|$ftp -n")) {
            warn "Couldn't open ftp: $!\n";
            chdir $dir; return;
        }

        my @dialog = split(/\n/, <<"END_FTP");
open $host
user anonymous anonymous\@example.com
cd $path
binary
get $file $file
quit
END_FTP
        foreach (@dialog) { $fh->print("$_\n") }
        $fh->close;
    } }
    else {
        warn "No working 'ftp' program available!\n";
        chdir $dir; return;

 view all matches for this distribution


Acme-Tests

 view release on metacpan or  search on metacpan

inc/Module/Install/Fetch.pm  view on Meta::CPAN

        LWP::Simple::mirror($args{url}, $file);
    }
    elsif (eval { require Net::FTP; 1 }) { eval {
        # use Net::FTP to get past firewall
        my $ftp = Net::FTP->new($host, Passive => 1, Timeout => 600);
        $ftp->login("anonymous", 'anonymous@example.com');
        $ftp->cwd($path);
        $ftp->binary;
        $ftp->get($file) or (warn("$!\n"), return);
        $ftp->quit;
    } }

inc/Module/Install/Fetch.pm  view on Meta::CPAN

        unless ($fh->open("|$ftp -n")) {
            warn "Couldn't open ftp: $!\n";
            chdir $dir; return;
        }

        my @dialog = split(/\n/, <<"END_FTP");
open $host
user anonymous anonymous\@example.com
cd $path
binary
get $file $file
quit
END_FTP
        foreach (@dialog) { $fh->print("$_\n") }
        $fh->close;
    } }
    else {
        warn "No working 'ftp' program available!\n";
        chdir $dir; return;

 view all matches for this distribution


Acme-Thoroughly-Modern-Perl

 view release on metacpan or  search on metacpan

lib/Acme/Thoroughly/Modern/Perl.pm  view on Meta::CPAN

Finding a way to use this module, and the consequences of doing so, is the
sole responsibility of the user!

=head1 NOTE

Acme employs the finest technology available to ensure the quality of its
products. There are no user-servicable parts inside. For your own safety,
DO NOT EXAMINE THE CONTENTS OF THIS PACKAGE!

=cut

 view all matches for this distribution


Acme-Tie-Eleet

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN

Revision history for Acme::Tie::Eleet

High-level changelog
====================

1.0.x   kwalitee release
0.3x    TIESCALAR
0.1x    cleaning, bugfixes, documentation
0.0x    initial work:


Low-level changelog
===================

1.0.2 Mon Nov 26 13:48:05 CET 2007
 - kwalitee/cpants release

 view all matches for this distribution


Acme-Time-Constant

 view release on metacpan or  search on metacpan

.mailmap  view on Meta::CPAN

# git help shortlog
# newname <newaddr> oldname <oldaddr>
<kentnl@cpan.org> <kentfredric@gmail.com>

 view all matches for this distribution


Acme-Timecube

 view release on metacpan or  search on metacpan

lib/Acme/Timecube.pm  view on Meta::CPAN

    my $tc = Acme::Timecube->new();

    # Preach cubic wisdom
    $tc->preach;

    # Deliver a discourse on 4 corner day logic
    $tc->discourse;

    # A lecture on why you are a stupid educated fool
    $tc->lecture;

 view all matches for this distribution


Acme-Tools

 view release on metacpan or  search on metacpan

Tools.pm  view on Meta::CPAN

  decode_num
  between
  btw
  curb
  bound
  log10
  log2
  logn
  distinct
  in
  in_num
  uniq
  union

Tools.pm  view on Meta::CPAN

  bfdimensions
  $PI
  install_acme_command_tools

  $Dbh
  dlogin
  dlogout
  drow
  drows
  drowc
  drowsc
  dcols

Tools.pm  view on Meta::CPAN

   !defined$s     ? undef
  :!length($s)    ? ''
  :$s<0           ? '-'.sec_readable(-$s)
  :$s<60 && int($s)==$s
                  ? $s."s"
  :$s<60          ? sprintf("%.*fs",int(3+-log($s)/log(10)),$s)
  :$s<3600        ? int($s/60)."m " .($s%60)        ."s"
  :$s<24*3600     ? int($s/$h)."h " .int(($s%$h)/60)."m"
  :$s<366*24*3600 ? int($s/$d)."d " .int(($s%$d)/$h)."h"
  :                 int($s/$y)."yr ".int(($s%$y)/$d)."d";
}

Tools.pm  view on Meta::CPAN

    }
  }
  return fractional($n) if !$l and !recursed() and $dec>6 and substr($n,-1) and substr($n,-1)--;
  print "l=$l max=$max\n";
  $ne="9" x $l;
  print log($n),"\n";
  my $st=sub{print "status: ".($te/$ne)."   n=$n   ".($n/$te*$ne)."\n"};
  while($n/$te*$ne<0.99){ &$st(); $ne*=10 }
  while($te/$n/$ne<0.99){ &$st(); $te*=10 }
  &$st();
  while(1){

Tools.pm  view on Meta::CPAN

  $val > $max ? $max :
                $val;
}
sub bound { curb(@_) }

=head2 log10

=head2 log2

=head2 logn

 print log10(1000);                  # prints 3
 print log10(10000*sqtr(10));        # prints 4.5
 print log2(16);                     # prints 4
 print logn(4096, 8);                # prints 4 (12/3=4)
 print logn($PI, 2.71828182845905);  # same as  print log($PI)  using perls builtin log()

=cut

sub log10 { log($_[0]) / log(10)    }
sub log2  { log($_[0]) / log(2)     }
sub logn  { log($_[0]) / log($_[1]) }

=head1 STRINGS

=head2 upper

Tools.pm  view on Meta::CPAN


Returns the I<geometric average> (a.k.a I<geometric mean>) of a list of numbers.

 print geomavg(10,100,1000,10000,100000);               # 1000
 print 0+ (10*100*1000*10000*100000) ** (1/5);          # 1000 same thing
 print exp(avg(map log($_),10,100,1000,10000,100000));  # 1000 same thing, this is how geomavg() works internally

=cut

sub geomavg { exp(avg(map log($_), @_)) }

=head2 harmonicavg

Returns the I<harmonic average> (a.k.a I<geometric mean>) of a list of numbers. L<http://en.wikipedia.org/wiki/Harmonic_mean>

Tools.pm  view on Meta::CPAN

    do {
      $x1=2.0*rand()-1.0;
      $x2=2.0*rand()-1.0;
      $w=$x1*$x1+$x2*$x2;
    } while $w>=1.0;
    $w=sqrt(-2.0*log($w)/$w) * $stddev;
    push @r,  $x1*$w + $avg,
              $x2*$w + $avg;
  }
  pop @r if @r > $num;
  return $r[0] if @_<3;

Tools.pm  view on Meta::CPAN

C<%Acme::Tools::IPADDR_memo> hash) so only the first loopup on a
particular IP number might take some time.

Some few DNS loopups can take several seconds.
Most is done in a fraction of a second. Due to this slowness, medium to high traffic web servers should
probably turn off hostname lookups in their logs and just log IP numbers by using
C<HostnameLookups Off> in Apache C<httpd.conf> and then use I<ipaddr> afterwards if necessary.

=cut

our %IPADDR_memo;

Tools.pm  view on Meta::CPAN


Extentions C<.gz>, C<.bz2> and C<.xz> are recognized for decompression. See also C<writefile()> and C<openstr()>.

=cut

#http://blogs.perl.org/users/leon_timmermans/2013/05/why-you-dont-need-fileslurp.html
#todo: readfile with grep-filter code ref in a third arg (avoid reading all into mem)

sub readfile {
  my($filename,$ref)=@_;
  if(@_==1){

Tools.pm  view on Meta::CPAN

meaning and is replaced by color codings depending on the letter
following the C<¤>.

B<Output:> The same string, but with C<¤letter> replaced by ANSI color
codes respected by many types terminal windows. (xterm, telnet, ssh,
telnet, rlog, vt100, cygwin, rxvt and such...).

B<Codes for ansicolor():>

 ¤r red
 ¤g green

Tools.pm  view on Meta::CPAN


Input, two numeric arguments: Capacity and error_rate.

Outputs an array of two numbers: m and k.

  m = - n * log(p) / log(2)**2   # n = capacity, m = bits in filter (divide by 8 to get bytes)
  k = log(1/p) / log(2)          # p = error_rate, uses perls internal log() with base e (2.718)

...that is: m = the best number of bits in the filter and k = the best
number of hash functions optimized for the given capacity (n) and
error_rate (p). Note that k is a dependent only of the error_rate.  At
about two percent error rate the bloom filter needs just the same

Tools.pm  view on Meta::CPAN


=head2 Theory and math behind bloom filters

L<http://www.internetmathematics.org/volumes/1/4/Broder.pdf>

L<http://blogs.sun.com/jrose/entry/bloom_filters_in_a_nutshell>

L<http://pages.cs.wisc.edu/~cao/papers/summary-cache/node8.html>

See also Scaleable Bloom Filters: L<http://gsd.di.uminho.pt/members/cbm/ps/dbloom.pdf> (not implemented in Acme::Tools)

Tools.pm  view on Meta::CPAN

  my($n,$p,$mink,$maxk, $k,$flen,$m)=
    @_==1 ? (@{$_[0]}{'capacity','error_rate','min_hashfuncs','max_hashfuncs'},1)
   :@_==2 ? (@_,1,100,1)
          : croak "Wrong number of arguments (".@_."), should be 2";
  croak "p ($p) should be > 0 and < 1" if not ( 0<$p && $p<1 );
  $m=-1*$_*$n/log(1-$p**(1/$_)) and (!defined $flen or $m<$flen) and ($flen,$k)=($m,$_) for $mink..$maxk;
  $flen = int(1+$flen);
  return ($flen,$k);
}
sub bfdimensions {
  my($n,$p,$mink,$maxk)=
    @_==1 ? (@{$_[0]}{'capacity','error_rate','min_hashfuncs','max_hashfuncs'})
   :@_==2 ? (@_,1,100)
          : croak "Wrong number of arguments (".@_."), should be 2";
  my $k=log(1/$p)/log(2);           # k hash funcs
  my $m=-$n*log($p)/log(2)**2;      # m bits in filter
  return ($m+0.5,min($maxk,max($mink,int($k+0.5))));
}

#crontab -e
#01 4,10,16,22 * * * /usr/bin/perl -MAcme::Tools -e'Acme::Tools::_update_currency_file("/var/www/html/currency-rates")' > /dev/null 2>&1

Tools.pm  view on Meta::CPAN


sub cmd_rttop   { die "rttop: not implemented here yet.\n" }
sub cmd_whichpm { die "whichpm: not implemented here yet.\n" } #-a (all, inkl VERSION og ls -l)
sub cmd_catal   { die "catal: not implemented here yet.\n" } #-a (all, inkl VERSION og ls -l)
#todo: cmd_tabdiff (fra sonyk)
#todo: cmd_catlog (ala catal med /etc/catlog.conf, default er access_log)

=head1 DATABASE STUFF - NOT IMPLEMENTED YET

Uses L<DBI>. Comming soon...

  $Dbh
  dlogin
  dlogout
  drow
  drows
  drowc
  drowsc
  dcols

Tools.pm  view on Meta::CPAN

  die;
}

our($Dbh,@Dbh,%Sth);
our %Dbattr=(RaiseError => 1, AutoCommit => 0); #defaults
sub dlogin {
  my $connstr=shift();
  my %attr=(%Dbattr,@_);
  my $type=dtype($connstr);
  my($dsn,$u,$p)=('','','');
  if($type eq 'SQLite'){

Tools.pm  view on Meta::CPAN

  }
  elsif($type eq 'Pg'){
    croak "todo";
  }
  else{
    croak "dblogin: unknown database type for connection string $connstr\n";
  }
  $dsn="dbi:$type:$dsn";
  push @Dbh, $Dbh if $Dbh; #local is better?
  require DBI;
  $Dbh=DBI->connect($dsn,$u,$p,\%attr); #connect_cached?
}
sub dlogout {
  $Dbh->disconnect;
  $Dbh=pop@Dbh if @Dbh;
}
sub drow {
  my($q,@b)=_dattrarg(@_);

Tools.pm  view on Meta::CPAN

# memoize_limit_size() #lru
# memoize_file_limit_size()
# memoize_memcached         http://search.cpan.org/~dtrischuk/Memoize-Memcached-0.03/lib/Memoize/Memcached.pm
# hint on http://perl.jonallen.info/writing/articles/install-perl-modules-without-root

# sub mycrc32 {  #http://billauer.co.il/blog/2011/05/perl-crc32-crc-xs-module/  eller String::CRC32::crc32 som er 100 x raskere enn Digest::CRC::crc32
#  my ($input, $init_value, $polynomial) = @_;
#  $init_value = 0 unless (defined $init_value);
#  $polynomial = 0xedb88320 unless (defined $polynomial);
#  my @lookup_table;
#  for (my $i=0; $i<256; $i++) {

Tools.pm  view on Meta::CPAN

                  Array subs: joinr perm permute permute_continue pile sortby subarrays
                  Other subs: btw in_iprange ipnum_ok iprange_ok opts s2t

 0.24  Feb 2019   fixed failes on perl 5.16 and older

 0.23  Jan 2019   Subs: logn, egrep, which. More UTF-8 "oriented" (lower, upper, ...)
                  Commands: zsize, finddup, due (improved), conv (improved, [MGT]?Wh
                  and many more units), due -M for stdin of filenames.

 0.22  Feb 2018   Subs: subarr, sim, sim_perm, aoh2sql. command: resubst

 0.21  Mar 2017   Improved nicenum() and its tests

 0.20  Mar 2017   Subs: a2h cnttbl h2a log10 log2 nicenum rstddev sec_readable
                  throttle timems refa refaa refah refh refha refhh refs
                  eachr globr keysr popr pushr shiftr splicer unshiftr valuesr
                  Commands: 2bz2 2gz 2xz z2z

 0.172 Dec 2015   Subs: curb openstr pwgen sleepms sleepnm srlz tms username

 view all matches for this distribution


( run in 1.149 second using v1.01-cache-2.11-cpan-49f99fa48dc )