# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4

PortSystem          1.0
PortGroup           python 1.0

name                py-about-time
version             4.2.2
revision            0

categories-append   devel
platforms           {darwin any}
supported_archs     noarch
license             MIT
maintainers         nomaintainer

description         Easily measure timing and throughput of code blocks, with beautiful human friendly representations.
long_description    {*}${description}

homepage            https://github.com/rsalmei/about-time

distname            about_time-${version}

checksums           rmd160  15c8e36dec242999d32ffa52a356b39d22f0ad6f \
                    sha256  3562885d528d66a40e02be0bc0e893920e2396a9f4b632eb9148e0c8ff47078f \
                    size    18351

python.versions     310 311 312 313 314

if {${name} ne ${subport}} {
    patchfiles      patch-setuptools-pyproject.toml.diff

    post-destroot {
        set docdir ${prefix}/share/doc/${subport}
        xinstall -d ${destroot}${docdir}
        xinstall -m 0644 -W ${worksrcpath} README.md LICENSE \
            ${destroot}${docdir}

        file delete -force ${destroot}/${python.prefix}/LICENSE
    }

    test.run        yes
}
