# -*- 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/kubernetes-sigs/kustomize 5.8.1 kustomize/v
revision            0

categories          devel
installs_libs       no
license             Apache-2
maintainers         {breun @breun} \
                    {gmail.com:herby.gillot @herbygillot} \
                    openmaintainer

description         Customize raw, template-free YAML files for multiple purposes, like Kubernetes

long_description    kustomize lets you customize raw, template-free YAML files for multiple purposes, \
                    leaving the original YAML untouched and usable as is. \
                    \
                    kustomize targets kubernetes\; it understands and can patch kubernetes style API objects. \
                    It\'s like make, in that what it does is declared in a file, \
                    and it\'s like sed, in that it emits edited text.

homepage            https://kustomize.io

checksums           rmd160  e78d232dcaaad0a7ce525a2dbccd06ee00f8f4c0 \
                    sha256  4ea5a974c46ad6efcde4fd9c339ab1bd278a80b6872dda2d1a366936e4638475 \
                    size    3574294

build.dir           ${worksrcpath}/${name}

build.args          -ldflags \" \
                        -s \
                        -X sigs.k8s.io/kustomize/api/provenance.version=${version} \
                        -X sigs.k8s.io/kustomize/api/provenance.gitCommit=unknown \
                        -X sigs.k8s.io/kustomize/api/provenance.buildDate=unknown \
                    \"

# FIXME: This port currently can't be built without allowing go mod to fetch
# dependencies during the build phase. See
# https://trac.macports.org/ticket/61192
go.offline_build no

destroot {
    xinstall -m 0755 ${build.dir}/${name} ${destroot}${prefix}/bin/
}

# https://github.com/kubernetes-sigs/kustomize/blob/master/cmd/config/docs/commands/completion.md
notes "
To install shell completion for supported shells run:

    kustomize install-completion

To uninstall shell completion:

    COMP_UNINSTALL=1 kustomize install-completion
"
