# -*- 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-filelock
version             3.19.1
revision            0

platforms           {darwin any}
supported_archs     noarch
license             public-domain
maintainers         {@funasoul gmail.com:funasoul} openmaintainer

description         A platform independent file lock
long_description    This package contains a single module, which implements \
                    a platform independent file lock in Python, which \
                    provides a simple way of inter-process communication:

homepage            https://py-filelock.readthedocs.io/

checksums           rmd160  6cc46b5f241cacdba0fe88ef8bde735f2358ed3b \
                    sha256  66eda1888b0171c998b35be2bcc0f6d75c388a7ce20c3f3f37aa8e96c2dddf58 \
                    size    17687

# keep version for Python 2.7, this is an (indirect) dependencies of py-virtualenv
# See: <https://trac.macports.org/wiki/Python#VersionPolicy>
python.versions     27 39 310 311 312 313 314

if {${name} ne ${subport}} {
    if {${python.version} == 27} {
        version     3.2.1
        revision    0
        epoch       1

        checksums   rmd160  4438a50fb193ec08f29631a5fbc657a74b5a084d \
                    sha256  9cdd29c411ab196cf4c35a1da684f7b9da723696cb356efa45bf5eb1ff313ee3 \
                    size    202950

        depends_build-append \
                    port:py${python.version}-setuptools_scm \
                    port:py${python.version}-toml
    } else {
        python.pep517_backend hatch

        depends_build-append \
                    port:py${python.version}-hatch-vcs

        test.run    yes

        depends_test-append \
                        port:py${python.version}-pytest-mock
    }

    livecheck.type  none
}
