# -*- 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
# $Id: Portfile 119960 2014-05-12 09:42:35Z stromnov@macports.org $

PortSystem          1.0
PortGroup           python 1.0

name                py-alembic
version             0.6.5
revision            0
categories-append   databases
platforms           darwin
license             MIT

python.versions     27 33 34

maintainers         stromnov openmaintainer

description         A database migration tool for SQLAlchemy.
long_description    ${description}

homepage            http://bitbucket.org/zzzeek/alembic
master_sites        https://pypi.python.org/packages/source/a/alembic/

distname            alembic-${version}

checksums           rmd160  3ca495b647ac0abe65ce876141365fa7289b51b2 \
                    sha256  17bfa1bb48bbc83e9db3a31df146a3b851172616aac9fbc6d40cad426e87e34c

if {${name} ne ${subport}} {
    depends_build-append \
                        port:py${python.version}-setuptools

    depends_lib-append  port:py${python.version}-sqlalchemy \
                        port:py${python.version}-mako

    livecheck.type      none
} else {
    livecheck.type      regex
    livecheck.url       ${master_sites}
    livecheck.regex     {alembic-(\d+(?:\.\d+)*)\.[tz]}
}
