{% set version = '1.0-6' %}

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

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

source:
  fn: brew_{{ version }}.tar.gz
  url:
    - https://cran.r-project.org/src/contrib/brew_{{ version }}.tar.gz
    - https://cran.r-project.org/src/contrib/Archive/brew/brew_{{ version }}.tar.gz
  sha256: d70d1a9a01cf4a923b4f11e4374ffd887ad3ff964f35c6f9dc0f29c8d657f0ed

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

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

requirements:
  build:
    - r-base

  run:
    - r-base

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

about:
  home: https://CRAN.R-project.org/package=brew
  license: GPL-2
  summary: brew implements a templating framework for mixing text and R code for report generation.
    brew template syntax is similar to PHP, Ruby's erb module, Java Server Pages, and
    Python's psp module.
  license_family: GPL2

extra:
  recipe-maintainers:
    - johanneskoester
    - bgruening
