# -*- 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/danielmiessler/Fabric 1.4.470 v
revision            0
name                [string tolower ${github.project}]
categories          llm
maintainers         {i0ntempest @i0ntempest} openmaintainer
license             MIT

description         open-source framework for augmenting humans using AI
long_description    ${name} is an ${description}. It provides a modular system for solving specific problems\
                    using a crowdsourced set of AI prompts that can be used anywhere.

homepage            https://danielmiessler.com/p/fabric-origin-story

checksums           rmd160  943e08a4994a6bfcd33303c751d4f7091a995b7b \
                    sha256  bd632fc8681767e76ae86f0fe09401decd7b6d093ea9ecc8171240bc78196285 \
                    size    20871999

# go2port fails on too many packages to be manually fixable
go.offline_build    no
go.toolchain_min    1.26.0
build.args          -o ./${name} -ldflags '-s -w' ./cmd/${name}

destroot {
    xinstall -m 0755 ${worksrcpath}/${name} ${destroot}${prefix}/bin/
    xinstall -d ${destroot}${prefix}/share/bash-completion/completions \
                ${destroot}${prefix}/share/zsh/site-functions \
                ${destroot}${prefix}/share/fish/vendor_completions.d
    xinstall -m 0644 ${worksrcpath}/completions/${name}.bash ${destroot}${prefix}/share/bash-completion/completions
    xinstall -m 0644 ${worksrcpath}/completions/_${name} ${destroot}${prefix}/share/zsh/site-functions
    xinstall -m 0644 ${worksrcpath}/completions/${name}.fish ${destroot}${prefix}/share/fish/vendor_completions.d
}
