# -*- 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           makefile    1.0
PortGroup           sourcehut   1.0

sourcehut.setup     rjarry aerc 0.22.0
revision            0

homepage            https://aerc-mail.org

description         Terminal-based email client.

long_description \
    ${name} is an email client that runs in your terminal, featuring editing \
    emails in an embedded terminal tmux-style and first-class support for \
    working with Git & email.

categories          mail
installs_libs       no
license             MIT
maintainers         {gmail.com:herby.gillot @herbygillot} \
                    openmaintainer

checksums           rmd160  6566d704a75c0dea24ee842fcefa86a37a87b169 \
                    sha256  f1cd5e358fd836051d4d88c189ecaa025a108b729281985525b45b13bc49e70f \
                    size    641634

depends_build-append \
                    port:go \
                    port:scdoc

default_variants    +notmuch

variant notmuch description {Enable support for notmuch integration} {
    depends_lib-append \
                    port:notmuch
    build.args-append \
                    GOFLAGS="-tags=notmuch"
}

build.pre_args-append \
                    VERSION=${version}

build.target

post-destroot {
    delete ${destroot}${prefix}/share/applications/aerc.desktop
}
