Files

55 lines
2.1 KiB
Tcl

# -*- 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/suzuki-shunsuke/pinact 4.1.0 v
go.offline_build no
categories security
maintainers {macports.halostatue.ca:austin @halostatue} \
openmaintainer
license MIT
description A CLI to edit GitHub Workflow and Composite action files and pin \
versions of Actions and Reusable Workflows. pinact can also update \
their versions and verify version annotations.
long_description {*}${description}
checksums ${distname}${extract.suffix} \
rmd160 6055da1f63caabe4c7b3a807b00837afa7487bcb \
sha256 0305c7db5cfcb2a62f7f5faa74e7cc3312c9ec10cbe01eadc23128d6a119eb03 \
size 105638
livecheck.regex {v(\d+\.\d+\.\d+)$}
build.args-append -ldflags \"-X main.version=${version} -X main.commit=MacPorts \" \
./cmd/pinact
post-build {
system "${worksrcpath}/${name} completion bash > ${worksrcpath}/${name}.bash"
system "${worksrcpath}/${name} completion fish > ${worksrcpath}/${name}.fish"
system "${worksrcpath}/${name} completion zsh > ${worksrcpath}/${name}.zsh"
}
destroot {
xinstall -m 0755 ${worksrcpath}/${name} ${destroot}${prefix}/bin/
set bash_completions_dir share/bash-completion/completions
set fish_completions_dir share/fish/vendor_completions.d
set zsh_completions_dir share/zsh/site-functions
xinstall -d ${destroot}${prefix}/${bash_completions_dir}
xinstall ${worksrcpath}/${name}.bash \
${destroot}${prefix}/${bash_completions_dir}/${name}
xinstall -d ${destroot}${prefix}/${fish_completions_dir}
xinstall ${worksrcpath}/${name}.fish \
${destroot}${prefix}/${fish_completions_dir}
xinstall -d ${destroot}${prefix}/${zsh_completions_dir}
xinstall ${worksrcpath}/${name}.zsh \
${destroot}${prefix}/${zsh_completions_dir}/_${name}
}