# -*- 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           golang 1.0

go.setup            github.com/cpuguy83/go-md2man 2.0.7 v
# Delete this on next update to use golang PortGroup's default ('archive')
github.tarball_from tarball
revision            0

categories          textproc
maintainers         {judaew @judaew} openmaintainer
license             MIT

description         Converts markdown into roff (man pages).
long_description    {*}${description}

checksums           ${distname}${extract.suffix} \
                        rmd160  823bc7b17c4d9fb7a9a2b955522fdb1defbfd4d3 \
                        sha256  397b066e0e349873b80cb888ebc2e1b7d7436ba54a63ef5a990933df68b301c5 \
                        size    11353

go.vendors          github.com/russross/blackfriday \
                        lock    v2.1.0 \
                        rmd160  c42a9332a2c2f3074c6f7e8d37a58d6148d2af08 \
                        sha256  c4df56f2012a7d16471418245e78b5790569e27bbe8d72a860d7117a801a7fae \
                        size    92950

destroot {
    xinstall -m 0755 ${worksrcpath}/${name} ${destroot}${prefix}/bin/

    system -W ${worksrcpath} "./${name} -in=${name}.1.md -out=${name}.1"
    xinstall -m 0644 ${worksrcpath}/${name}.1 \
        ${destroot}${prefix}/share/man/man1
}
