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

github.setup        tadfisher pass-otp 1.2.0 v
github.tarball_from releases
revision            1

categories          security
supported_archs     noarch
platforms           any
license             GPL-3
maintainers         {loicp.eu:loic-github @lpefferkorn} \
                    {judaew @judaew} \
                    openmaintainer

description         A pass extension for managing one-time-password (OTP) tokens
long_description    {*}${description}

checksums           rmd160  3ac479108fa4717af3142f7468e6abb2e57622f4 \
                    sha256  5720a649267a240a4f7ba5a6445193481070049c1d08ba38b00d20fc551c3a67 \
                    size    46789

depends_run         port:oath-toolkit \
                    port:pass \
                    port:qrencode

use_configure       no
build {}

destroot.env-append PREFIX=${prefix}
destroot.env-append BASHCOMPDIR=${prefix}/share/bash-completion/completions

notes {
    To use pass-otp bash completion, add the following lines at the end of your .bash_profile:
        [[ -r "${prefix}/share/bash-completion/completions/pass-otp" ]] && source "${prefix}/share/bash-completion/completions/pass-otp"
}