# -*- 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/bmf-san/ggc 3.2.0
revision            0

description         \
    A modern Git CLI tool with both traditional command-line and interactive \
    incremental-search UI.

long_description    \
    ${name} is a Git tool written in Go, offering both traditional CLI \
    commands and an interactive interface with incremental search. You can \
    either run subcommands like ggc add directly, or launch the interactive \
    mode by simply typing ggc. Designed to be fast, user-friendly, and \
    extensible.

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

build.args-append   \
    -ldflags \" -X main.version=${version} \"

destroot {
    xinstall -m 0755 ${worksrcpath}/${name} ${destroot}${prefix}/bin/
    # Check ${worksrcpath}/tools/completions/ for all supported shells
    set comp_path(bash) ${destroot}${prefix}/share/bash-completion/completions/${name}
    set comp_path(fish) ${destroot}${prefix}/share/fish/completions/${name}.fish
    set comp_path(zsh)  ${destroot}${prefix}/share/zsh/site-functions/_${name}
    foreach shell {bash fish zsh} {
        xinstall -d [file dirname $comp_path(${shell})]
        xinstall -m 0644 ${worksrcpath}/tools/completions/${name}.${shell} $comp_path(${shell})
    }
}

checksums           ${distname}${extract.suffix} \
                        rmd160  cb409e1a070eabfccc98beefee8ae2c95e515d05 \
                        sha256  72609300de8dec2f0cfdd9f94591440975591f4f939e9b2b788c3117128fbcfd \
                        size    1167167

go.vendors          gopkg.in/yaml.v3 \
                        lock    v3.0.1 \
                        rmd160  e85ac1368fb7f9ef945b7fd7bd608a1f0d261c12 \
                        sha256  f3ea6be3f405ec25f8799773355aba54f8831d11f5315a01155bdc69b92eca7b \
                        size    91208 \
                    gopkg.in/check.v1 \
                        lock    20d25e280405 \
                        rmd160  412aa0d109919182ff84259e9b5bbc9f24d78117 \
                        sha256  233f8faf427ce6701ac3427f85c28bc6b6ae7cdc97a303a52873c69999223325 \
                        size    30360 \
                    golang.org/x/term \
                        lock    v0.34.0 \
                        rmd160  c17f07f42813271264c518e71ffb0e025c096903 \
                        sha256  ed10832a496fc6e6af32e8a0933942b042f362bb117ccb232a0553bc057da308 \
                        size    15937 \
                    golang.org/x/sys \
                        lock    v0.35.0 \
                        rmd160  94ac3a8dd72c3a5b79bc8f068285b77634935368 \
                        sha256  b1c65be93d2d2ced17bd5ad9386a2385fd7258c708d3879f69e2485a1cea1011 \
                        size    1531744
