# -*- 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
PortGroup           cmake   1.1

github.setup        GothenburgBitFactory timewarrior 1.9.0 v
github.tarball_from releases
revision            0

homepage            https://timewarrior.net

description         Timewarrior is Free and Open Source Software that tracks \
                    time from the command line.

long_description    Timewarrior is a time tracking utility that offers simple \
                    stopwatch features as well as sophisticated \
                    calendar-based backfill, along with flexible reporting.

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

distname            timew-${version}

checksums           rmd160  ef4605fffb6e4cf539adbebb23cdc683bf326421\
                    sha256  24365dc1537aa7b0b8c33877df9933a5b8b86e86a25858a5126b1eb4f3bc0b08\
                    size    324610

# Hardcoding C++ runtime is either redundant or breaking.
patchfiles-append       patch-fix-cxx.diff

# Required by the build:
compiler.cxx_standard   2017

post-destroot {
    # Install bash completions
    set bash_comp_path ${prefix}/share/bash-completion/completions

    xinstall -d ${destroot}${bash_comp_path}

    xinstall -m 0644 ${worksrcpath}/completion/timew-completion.bash \
        ${destroot}${bash_comp_path}/timew
}

github.livecheck.regex {([0-9.]+)}
