App-Fetchware
view release on metacpan or search on metacpan
1.013 2014-09-06 22:01:01-04:00 America/New_York
- Fixed dozens of CPAN Tester FAIL reports. These reports FAILed mostly
beause they were run under a smoker, which is a different environment, then
I test Fetchware under.
- Fixed the upgrade tests actually using the users own fetchware package
path. Now a temp file is used instead.
- Switch use of $^X to $Config{perlpath}, which solves some bugs in some
smoker configurations.
- Fixed a hilarious bug due to localizations. I used a direct string
comparison where $! was in the string, and I guess under different
locales you can get languages other than english to come from using $!
in a string.
1.012 2014-09-05 21:23:55-04:00 America/New_York
- Fixed botched use of $ENV{AUTOMATED_TESTING} to skip the interactive new
command tests.
- Fixed last of my use of smartmatch since its sadly been marked
experimental.
1.011 2014-09-05 00:59:30-04:00 America/New_York
lib/App/Fetchware.pm view on Meta::CPAN
This extension mechanism is also very easy for Perl programmers, because you're
basically I<subclassing> App::Fetchware, only you do it using
L<App::Fetchware::ExportAPI> and L<App::Fetchware::CreateConfigOptions>. See
section L<Implement your fetchware extension.> for full details.
=head2 How do I fix the verification failed error.
Fetchware is designed to always attempt to verify the software archives it
downloads even if you failed to configure fetchware's verification settings. It
will try to guess what those setting should be using simple heuristics. First it
will try gpg verificaton, then sha1 verification, and finally md5 verification.
If all fail, then fetchware exit failure with an appropriate error message.
When you get this error message
L<read fetchware's documentation on how to set this up|/4. Add mandatory verification settings>.
=head2 How do I make fetchware log to a file instead of STDOUT?
You can't fetchware does not have any log file support. However, you can simply
redirect STDOUT to a file to make your shell redirect STDOUT to a file for you.
lib/App/Fetchware/Util.pm view on Meta::CPAN
{ # Bareblock just for the $MAGIC_NUMBER.
# Determine $front_magic
my $front_magic;
$front_magic = int(rand(8128389023));
# For no particular reason convert the random integer into hex, because I
# never store something in decimal and then exact same thing in hex.
$front_magic = $front_magic . sprintf("%x", $front_magic);
# Run srand() again to change random number generator between rand() calls.
# Not really necessary, but should make it harder to guess correct magic
# numbers.
srand(time());
# Same a $front_magic.
my $back_magic = int(rand(986487516));
# Octal this time :) for no real reason.
$back_magic = $back_magic . sprintf("%o", $back_magic);
my $MAGIC_NUMBER = $front_magic
. 'MAGIC_NUMBER_REPLACING_NEWLINE'
. $back_magic;
t/App-Fetchware-verify.t view on Meta::CPAN
};
subtest 'test verify()' => sub {
skip_all_unless_release_testing();
# test verify_method
# test gpg verify_method
# test sha1 verify_method
# test md5 verify_method
# Specify a DownloadURL to test some gpg_verify() guessing magic.
for my $verify_method (qw(gpg sha md5)) {
config_replace('verify_method', "$verify_method");
eval {verify($download_path, $package_path)};
unless ($@) {
pass("checked verify() verify_method $verify_method");
} else {
fail("checked verify() verify_method $verify_method");
}
}
( run in 0.833 second using v1.01-cache-2.11-cpan-702932259ff )