# -*- 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           github 1.0
PortGroup           python 1.0

github.setup        encode databases 0.8.0
# Change github.tarball_from to 'releases' or 'archive' next update
github.tarball_from tarball
revision            0
name                py-${github.project}
categories-append   devel

license             MIT
maintainers         nomaintainer
supported_archs     noarch
platforms           {darwin any}

description         Async database support for Python.
long_description    Databases gives you simple asyncio support for a \
                    range of databases. It allows you to make queries \
                    using the powerful SQLAlchemy Core expression \
                    language, and provides support for PostgreSQL, \
                    MySQL, and SQLite. Databases is suitable for \
                    integrating against any async Web framework, such \
                    as Starlette, Sanic, Responder, Quart, aiohttp, \
                    Tornado, or FastAPI.

checksums           rmd160  267085a0f2cf321be34628280696d2b687146eea \
                    sha256  83276d2acf746f8d813ff9046004c60f92363b62cb10a59d1b60acbdfbd6ef43 \
                    size    36465

python.versions     39 310

if {${name} ne ${subport}} {
    depends_run-append \
                    port:py${python.version}-aiopg \
                    port:py${python.version}-aiosqlite \
                    port:py${python.version}-asyncpg \
                    port:py${python.version}-asyncmy \
                    port:py${python.version}-sqlalchemy

    if {${python.version} < 310} {
        depends_run-append \
                    port:py${python.version}-aiomysql
    }

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

    test.run        yes
}
