# -*- 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-cloup
version             4.0.0
revision            0

categories-append   devel
platforms           {darwin any}
supported_archs     noarch
license             BSD
maintainers         {deldycke.com:kevin @kdeldycke} openmaintainer

description         Adds option groups, constraints, subcommand sections \
                    and help themes to Click
long_description    Cloup extends Click, the Python CLI framework, with \
                    option groups, constraints for group options, \
                    subcommand sections in the help screen and themeable \
                    help formatting.

homepage            https://github.com/janluke/cloup

checksums           rmd160  0a9cb816e2ab721c6a3bff59a86f2688a73f8d83 \
                    sha256  83b0870ee863bcc85129e40e1b208bcfdebe4cd2142e9ce1d0daf7d276cab038 \
                    size    252135

python.versions     311 312 313 314
python.pep517_backend hatch

if {${name} ne ${subport}} {
    depends_build-append \
                    port:py${python.version}-hatch-vcs
    depends_lib-append \
                    port:py${python.version}-click

    if {${python.version} < 312} {
        depends_lib-append \
                    port:py${python.version}-typing_extensions
    }

    # The typing and styling tests import typing_extensions on every version.
    depends_test-append \
                    port:py${python.version}-typing_extensions

    test.run            yes
    test.env-append     PYTHONPATH=${destroot}${python.pkgd}
}
