Graham Ollis 🔥🐉

NAME

Alien::Build::Plugin::Download::Git - Alien::Build plugin to download from git

VERSION

version 0.01

SYNOPSIS

 use alienfile;
 
 meta->prop->{start_url} = 'http://example.com/project-foo.git';
 plugin 'Download::Git' =>(
   version => qr/^v([0-9\.]+)$/,
 );

DESCRIPTION

This plugin downloads projects using git and selects the appropriate tag for building. Typically you want to build using the most recent production tag, not just whatever master happens to be at the moment.

This plugin uses these plugins to do the heavy lifting:

Alien::Build::Plugin::Fetch::Git
Alien::Build::Plugin::Prefer::SortVersions
ALien::Build::Plugin::Extract::Directory

In fact this:

 plugin 'Download::Git' => (
   filter  => $filter,
   version => $version,
 );

Is exactly the same as:

 plugin 'Fetch::Git';
 plugin 'Prefer::SortVersions' => (
   filter  => filter,
   version => $version,
 );
 plugin 'Extract::Directory';

About the only time you would opt to use Alien::Build::Plugin::Fetch::Git directly, (unless you are not into the whole brevity thing), is if you wanted to use something other that Alien::Build::Plugin::Prefer::SortVersions to choose which version you want to install.

PROPERTIES

filter

his is a regular expression that lets you filter out tags that you do not want to consider downloading. For example, if the tags included name such as

 v1.0.0
 v1.1.2
 old-feature-not-included
 something-else/entirely

You could specify a filter of qr/^v[0-9\.]+$/ to make sure only tags that appeared to be a version number are included.

version

Regular expression to parse out the version from tags. The regular expression should store the result in $1.

In the previous example you might use the regular expression qr/^v([0-9\.]+/.

SEE ALSO

Alien
Alien::Build
Alien::Build::Git
Alien::git

AUTHOR

Graham Ollis <plicease@cpan.org>

COPYRIGHT AND LICENSE

This software is copyright (c) 2017 by Graham Ollis.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.