# -*- 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        realm swiftlint 0.63.2
github.tarball_from archive
revision            0

platforms           {darwin >= 21}
categories          devel
license             MIT
maintainers         {gmail.com:christos.koninis @csknns} \
                    openmaintainer
description         Swift linter
long_description    A tool to enforce Swift style and conventions

checksums           rmd160  0eb914c39d3ea51811674471037117339e80bb49 \
                    sha256  e32149f1b325f84da442180e3e2083dfaf97b692623ba8656db7fee88842ce0b \
                    size    942912

# Clearing CPATH because of header conflicts with MacOSX13.sdk when using swiftPM build system
compiler.cpath

use_configure       no
use_xcode           yes

build.cmd           swift
build.target        build
build.args          --configuration release --disable-sandbox

test.run            yes
test.cmd            swift
test.target         test
test.args           --disable-sandbox

set builtproductdir ${worksrcpath}/.build/release

destroot {
    xinstall -m 755 ${builtproductdir}/${name} ${destroot}${prefix}/bin/
}
