{% set version = '0.8-2' %}

{% set posix = 'm2-' if win else '' %}
{% set native = 'm2w64-' if win else '' %}

package:
  name: r-ctv
  version: {{ version|replace("-", "_") }}

source:
  fn: ctv_{{ version }}.tar.gz
  url:
    - https://cran.r-project.org/src/contrib/ctv_{{ version }}.tar.gz
    - https://cran.r-project.org/src/contrib/Archive/ctv/ctv_{{ version }}.tar.gz
  sha256: 3b2f7708eb1fdfd8124ab1d0499e17b824eb9d427642d166abdb886eececfd76

build:
  number: 0
  skip: true  # [win32]

  rpaths:
    - lib/R/lib/
    - lib/

requirements:
  build:
    - r-base

  run:
    - r-base

test:
  commands:
    - $R -e "library('ctv')"  # [not win]
    - "\"%R%\" -e \"library('ctv')\""  # [win]

about:
  home: https://CRAN.R-project.org/package=ctv
  license: GPL-2 | GPL-3
  summary: 'Infrastructure for task views to CRAN-style repositories: Querying task views and
    installing the associated packages (client-side tools), generating HTML pages and
    storing task view information in the repository (server-side tools).'

  license_family: GPL3

extra:
  recipe-maintainers:
    - johanneskoester
    - bgruening
