FreeBSD::Pkgs::FindUpdates - Finds updates for FreeBSD pkgs by checking the ports index.


FreeBSD-Pkgs-FindUpdates documentation  | view source Contained in the FreeBSD-Pkgs-FindUpdates distribution.

Index


NAME

Top

FreeBSD::Pkgs::FindUpdates - Finds updates for FreeBSD pkgs by checking the ports index.

VERSION

Top

Version 0.2.1

SYNOPSIS

Top

This does use FreeBSD::Ports::INDEXhash. Thus if you want to specifiy the location of the index file, you will want to see the supported methodes for it in that module.

    use FreeBSD::Pkgs::FindUpdates;
    #initiates the module
    my $pkgsupdate = FreeBSD::Pkgs::FindUpdates->new();
    #finds changes
    my %changes=$pkgsupdate->find();
    #prints the upgraded stuff
    while(my ($name, $pkg) = each %{$changes{upgrade}}){
        print $name.' updated from "'.
              $pkg->{oldversion}.'" to "'.
              $pkg->{newversion}."\"\n";
    }
    #prints the downgraded stuff
    while(my ($name, $pkg) = each %{$changes{upgrade}}){
        print $name.' updated from "'.
              $pkg->{oldversion}.'" to "'.
              $pkg->{newversion}."\"\n";
    }

FUNCTIONS

Top

new

This initiate the module.

find

This finds any changes creates a hash.

Two arguements are optionally accepted. The first is a hash returned from INDEXhash

    #basic usage...
    my %changes=$pkgsupdate->find;

    #create the INDEXhash and pkgdb and then pass it
    my $pkgdb=FreeBSD::Pkgs->new;
    $pkgdb->parseInstalled({files=>0});
    my %index=INDEXhash();
    my %changes=$pkgsupdate->find(\%index, $pkgdb);

Changes Hash

Top

This hash contains several keys that are listed below. Each is a hash that contain several keys of their own. Please see the sub hash section for information on that.

The name of the installed package is used as the primary key in each.

downgrade

This is a hash that contains a list of packages to be down graded.

from

The keys to this hash are the packages that will be change from. The values are the names that it will changed to.

upgrade

This is a hash that contains a list of packages to be up graded.

same

This means there is no change.

to

The keys to this hash are the packages that will be change to. The values are the names that it will changed from.

sub hash

All three keys contain hashes that then contian these values.

old

This is the name of the currently installed package.

new

This is the name of what it will be changed to if upgraded/downgraded.

oldversion

This is the old version.

newversion

This is the version ofwhat it will be changed toif upgraded/downgraded.

port

This is the port that provides it.

ERROR

Top

1

No origin for a specified package. This is not a fatal error.

2

A line in the INDEX file is missing the path to the ports directory for that port.

AUTHOR

Top

Zane C. Bowers, <vvelox at vvelox.net>

BUGS

Top

Please report any bugs or feature requests to bug-freebsd-pkgs-findupdates at rt.cpan.org, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=FreeBSD-Pkgs-FindUpdates. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.

SUPPORT

Top

You can find documentation for this module with the perldoc command.

    perldoc FreeBSD::Pkgs::FindUpdates




You can also look for information at:

* RT: CPAN's request tracker

http://rt.cpan.org/NoAuth/Bugs.html?Dist=FreeBSD-Pkgs-FindUpdates

* AnnoCPAN: Annotated CPAN documentation

http://annocpan.org/dist/FreeBSD-Pkgs-FindUpdates

* CPAN Ratings

http://cpanratings.perl.org/d/FreeBSD-Pkgs-FindUpdates

* Search CPAN

http://search.cpan.org/dist/FreeBSD-Pkgs-FindUpdates

ACKNOWLEDGEMENTS

Top

COPYRIGHT & LICENSE

Top


FreeBSD-Pkgs-FindUpdates documentation  | view source Contained in the FreeBSD-Pkgs-FindUpdates distribution.