[csw-maintainers] gar tip
Sebastian Kayser
skayser at opencsw.org
Sun Jun 26 00:30:58 CEST 2011
* Ben Walton <bwalton at opencsw.org> wrote:
> Peter and I just realized that not everyone is aware of the templated
> GAR recipe feature. In opencsw/ (or opencsw/cpan, etc), you can type:
>
> gmake newpkg-foo
>
> This will give you a templated base recipe file. It's custom to each
> specialized category (cpan, etc) so that things like gmake
> newpkg-Some::Cool:Perl will generate a recipe for
> CSWpm-some-cool-perl/pm_some_cool_perl, etc.
When you use mgar you can already also use:
mgar newpkg <name> <version>
and it will populate the template's version field too. Beyond that (not
yet implemented), what would you think about populating the template
even further, by simply passing the upstream URL to newpkg?
mgar newpkg http://foo.org/files/bla-1.2.3.tar.gz
It would then:
* check whether the file is available
* regex-retrieve NAME (bla) and VERSION (1.2.3)
* regex-retrieve MASTER_SITES (http://foo.org/files/)
* adjust the DISTFILES .tar.gz extension (if != .tar.gz)
* possibly run an initial 'mgar makesum'
Helpful or too much magic?
Sebastian
More information about the maintainers
mailing list