[macports-ports] branch master updated: New port: pgbadger

Ryan Schmidt ryandesign at macports.org
Fri Apr 21 19:55:52 UTC 2017


> On Apr 21, 2017, at 12:25, Eric Hall <ricci at macports.com> wrote:
> 
> ghosthound pushed a commit to branch master
> in repository macports-ports.
> 
> 
> https://github.com/macports/macports-ports/commit/71033af1f4162235c6971ee899fd507f81bf9f48
> 
> The following commit(s) were added to refs/heads/master by this push:
> 
>      new 71033af  New port: pgbadger
> 
> 71033af is described below
> 
> 
> commit 71033af1f4162235c6971ee899fd507f81bf9f48
> 
> Author: Eric Hall <ricci at macports.com>
> AuthorDate: Fri Apr 21 10:25:40 2017 -0700
> 
> 
>     New port: pgbadger
> 
> ---
>  databases/pgbadger/Portfile | 49 +++++++++++++++++++++++++++++++++++++++++++++
>  1 file changed, 49 insertions(+)
> 
> 
> diff --git a/databases/pgbadger/Portfile b/databases/pgbadger/Portfile
> 
> new file mode 100644
> 
> index 0000000..f600d69
> 
> --- /dev/null
> 
> +++ b/databases/pgbadger/Portfile
> 
> @@ -0,0 +1,49 @@
> 
> +# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; truncate-lines: t -*- vim:fenc=utf-8:et:sw=4:ts=4:sts=4
> 
> +
> 
> +PortSystem          1.0
> 
> +PortGroup           github 1.0
> 
> +PortGroup           perl5 1.0
> 
> +
> 
> +name                pgbadger
> 
> +
> 
> +github.setup        dalibo ${name} 9.1

Correct usage of the github portgroup is:

github.setup dalibo pgbadger 9.1 v

No need for a separate name line.


> +revision            0
> 
> +
> 
> +categories          databases
> 
> +maintainers         nomaintainer
> 
> +description         PostgreSQL log analyzer with fully detailed reports and graphs.
> 
> +long_description    pgBadger is a PostgreSQL log analyzer built for speed with fully reports \
> 
> +                    from your PostgreSQL log file. It's a single and small Perl script that \
> 
> +                    outperforms any other PostgreSQL log analyzer.
> 
> +
> 
> +platforms           darwin
> 
> +license             BSD
> 
> +
> 
> +homepage            http://dalibo.github.io/${name}/
> 
> +
> 
> +## https://github.com/dalibo/pgbadger/archive/v9.1.tar.gz
> 
> +
> 
> +master_sites        https://github.com/dalibo/${name}/archive/
> 
> +distname            v${version}
> 
> +worksrcdir          ${name}-${version}

It is not intended that you should have to override master_sites, distname or worksrcdir; the github portgroup handles these for you. See the comments at the top of the github portgroup for examples of proper usage.

There is an open ticket in the issue tracker requesting support for archive URLs.




> +checksums           rmd160  baad3e6497f8a8d5f52ade429bddcbdade2d661a \
> 
> +                    sha256  2fd7166d74692cc7d87f00b37cc5c7c1c6eddf156372376d382a40f67d694011
> 
> +
> 
> +
> 
> +configure.perl      ${perl5.bin}
> 
> +perl5.branches      5.24
> 
> +
> 
> +configure {
> 
> +    system -W ${worksrcpath} "${perl5.bin} Makefile.PL INSTALLDIRS='perl'"
> 
> +}
> 
> +
> 
> +
> 
> +depends_lib-append  port:perl5 \
> 
> +                    port:p5-text-csv_xs

It is not proper to depend on a stub port such as one whose name begins with "p5-". Depend instead on the specific perl version of that module that you want, e.g. p5.24-test-csv_xs. The same goes for the perl5 port: don't depend on it if you actually need a specific version of perl, as you do here because you need a module; depend on perl5.24 instead.



> +livecheck.type      regex
> 
> +livecheck.url       ${github.raw}/master/${name}
> 
> +livecheck.regex     {VERSION\s*=\s*'([0-9\.]+)}
> 


These lines are unnecessary when the github portgroup is used correctly.




More information about the macports-dev mailing list