# -*- coding: utf-8; mode: tcl; tab-width: 4; truncate-lines: t; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:et:sw=4:ts=4:sts=4
# $Id: Portfile 71820 2010-09-24 00:34:03Z snc@macports.org $

PortSystem          1.0
PortGroup           python25 1.0

name                py25-coverage
version             3.4
categories-append   devel
platforms           darwin
maintainers         nomaintainer
description         Code coverage tool for Python
long_description    Coverage.py is a Python module that measures code \
                    coverage during Python execution. It uses the code \
                    analysis tools and tracing hooks provided in the Python \
                    standard library to determine which lines are \
                    executable, and which have been executed. The original \
                    version was written by Gareth Rees. I've updated it to \
                    determine executable statements more accurately.

homepage            http://nedbatchelder.com/code/coverage/
master_sites        http://pypi.python.org/packages/source/c/coverage/
distname            coverage-${version}

depends_lib-append  port:py25-distribute

checksums           md5     46782809578c8fd29912c124d2420842 \
                    sha1    fd244e9890ae8b235315123a82c25e0db1788c26

post-patch {
    # Permissions in the archive are 700
    # Set directories to 755, *.py to 755, other files to 644
    system "find ${worksrcpath} -type d -exec chmod 755 {} \\;"
    system "find ${worksrcpath} -type f -name '*.py' -exec chmod 775 {} \\;"
    system "find ${worksrcpath} -type f -not -name '*.py' -exec chmod 644 {} \\;"
}

livecheck.type      regex
livecheck.url       http://pypi.python.org/pypi/coverage
livecheck.regex     {coverage (\d+(?:\.\d+)*)}
