# $Id: Portfile 80801 2011-07-17 18:44:15Z and.damore@macports.org $

PortSystem          1.0
PortGroup           python26 1.0
name                py26-mercurial_keyring
version             0.4.5
categories-append   devel
license             GPL
maintainers         and.damore openmaintainer
description         Mercurial extension used to securely save passwords
long_description \
    mercurial_keyring is a Mercurial extension used to securely save HTTP and \
    SMTP authentication passwords in password databases (Gnome Keyring, KDE \
    KWallet, OSXKeyChain, specific solutions for Win32 and command line). This \
    extension uses and wraps services of the keyring library.

platforms           darwin

homepage            http://pypi.python.org/pypi/mercurial_keyring
master_sites        http://pypi.python.org/packages/source/m/mercurial_keyring
distname            mercurial_keyring-${version}

checksums           md5     7c24cd32f5f178bd14d3cccda564ccd3 \
                    sha1    e8c1353bdbd0a8dfd4fb2693799b5d9c6e7c8468 \
                    rmd160  0f80e43fe2fab208a54f1d89cb5ef5e997e0e6e3

depends_run         port:py26-keyring
depends_build       port:py26-distribute

variant use_setuptools description "relies on setuptools rather than distribute python module" {
    depends_build-delete    port:py26-distribute
    depends_build-append    port:py26-setuptools
}


post-destroot {
   xinstall -m 755 -d ${destroot}${prefix}/share/doc/${name}
   xinstall -m 644 -W ${worksrcpath} README.txt \
      ${destroot}${prefix}/share/doc/${name}
}

livecheck.url       [lindex ${master_sites} 0]
livecheck.regex     "mercurial_keyring-(\\d+(?:\\.\\d+)*)${extract.suffix}"

