# -*- 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

github.setup        curl wcurl 2025.02.24 v
revision            0
checksums           rmd160  9e6acbef6cf251e445ea6c4270841b83bcf7b062 \
                    sha256  640319b7a3dfd693a4a513ae603539b9e0632a706ed75f969765f5341f1a14c7 \
                    size    10854

categories          net www
license             Curl
maintainers         {ryandesign @ryandesign} openmaintainer
platforms           any
supported_archs     noarch

description         a simple wrapper around curl to easily download files

long_description    ${name} is a simple curl wrapper which lets you use curl \
                    to download files without having to remember any \
                    parameters. Simply call wcurl with a list of URLs you want \
                    to download and wcurl will pick sane defaults.

homepage            https://curl.se/wcurl/
github.tarball_from archive

depends_test        port:shunit2

depends_run         bin:curl:curl

use_configure       no

build {}

test.env-append     PATH=${worksrcpath}:$env(PATH)
test.run            yes
test.dir            ${worksrcpath}/tests
test.cmd            ./tests.sh
test.target

destroot {
    xinstall -m 0755 ${worksrcpath}/${name} ${destroot}${prefix}/bin
    xinstall -m 0444 ${worksrcpath}/${name}.1 ${destroot}${prefix}/share/man/man1
    set docdir ${prefix}/share/doc/${name}
    xinstall -d ${destroot}${docdir}
    xinstall -W ${worksrcpath} -m 0644 LICENSE README.md ${destroot}${docdir}
}
