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

github.setup        yadm-dev yadm 3.5.0
github.tarball_from archive
revision            0

categories          sysutils
platforms           any
license             GPL-3+
maintainers         {kollar.me:laszlo @lkollar} openmaintainer

description         Yet Another Dotfiles Manager

long_description    yadm is a tool for managing dotfiles. \
                    yadm is like having a version of Git that only \
                    operates on your dotfiles. If you know how to use \
                    Git, you already know how to use yadm.

homepage            https://yadm.io

checksums           sha256  2a15ed91238dd2f15db9905eb56702272c079ad9c37c505dfee69c6b5e9054b6 \
                    rmd160  e11038ecf65e2e0de50649d30d837758d7a43b45 \
                    size    116502

build.target        yadm

installs_libs       no
supported_archs     noarch
makefile.has_destdir \
                    yes

post-destroot {
    # Install shell completions
    xinstall -d ${destroot}${prefix}/share/bash-completion/completions
    xinstall ${worksrcpath}/completion/bash/${name} \
        ${destroot}${prefix}/share/bash-completion/completions/

    xinstall -d ${destroot}${prefix}/share/fish/vendor_completions.d/
    xinstall ${worksrcpath}/completion/fish/${name}.fish \
        ${destroot}${prefix}/share/fish/vendor_completions.d/

    xinstall -d ${destroot}${prefix}/share/zsh/site-functions
    xinstall ${worksrcpath}/completion/zsh/_${name} \
        ${destroot}${prefix}/share/zsh/site-functions/
}
