{% set version = "0.4" %}

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

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

source:
  fn: DT_{{ version }}.tar.gz
  url:
    - https://cran.r-project.org/src/contrib/DT_{{ version }}.tar.gz
    - https://cran.r-project.org/src/contrib/Archive/DT/DT_{{ version }}.tar.gz
  sha256: 3daa96b819ca54e5fbc2c7d78cb3637982a2d44be58cea0683663b71cfc7fa19

build:
  number: 0
  skip: true  # [win32]
  rpaths:
    - lib/R/lib/
    - lib/

requirements:
  build:
    - r-base
    - r-htmltools >=0.3.5
    - r-htmlwidgets >=0.6
    - r-magrittr
    - r-crosstalk

  run:
    - r-base
    - r-htmltools >=0.3.5
    - r-htmlwidgets >=0.6
    - r-magrittr
    - r-crosstalk

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

about:
  home: http://rstudio.github.io/DT
  license: GPL-3
  summary: Data objects in R can be rendered as HTML tables using the JavaScript library 'DataTables'
    (typically via R Markdown or Shiny). The 'DataTables' library has been included
    in this R package. The package name 'DT' is an abbreviation of 'DataTables'.
  license_family: GPL3

extra:
  recipe-maintainers:
    - johanneskoester
    - bgruening
