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

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

source:
  fn: flexdashboard_{{ version }}.tar.gz
  url:
    - {{ cran_mirror }}/src/contrib/flexdashboard_{{ version }}.tar.gz
    - {{ cran_mirror }}/src/contrib/Archive/flexdashboard/flexdashboard_{{ version }}.tar.gz
  sha256: fd18c05590bf4f544bd0f80fcedc87e0eaa24141ac8a4c487bf81f93f3b2c33b

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

requirements:
  build:
    - {{posix}}zip               # [win]
  host:
    - r-base
    - r-htmltools
    - r-htmlwidgets >=0.6
    - r-jsonlite
    - r-knitr >=1.13
    - r-rmarkdown >=1.0
    - r-shiny >=0.13
  run:
    - r-base
    - r-htmltools
    - r-htmlwidgets >=0.6
    - r-jsonlite
    - r-knitr >=1.13
    - r-rmarkdown >=1.0
    - r-shiny >=0.13

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

about:
  home: http://rmarkdown.rstudio.com/flexdashboard
  license: MIT
  summary: Format for converting an R Markdown document to a grid oriented dashboard. The dashboard
    flexibly adapts the size of it's components to the containing web page.
  license_family: MIT

extra:
  recipe-maintainers:
    - johanneskoester
    - bgruening
    - daler
    - jdblischak
    - cbrueffer
    - dbast
