{% set version = '3.0.0' %}

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

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

source:
  fn: huxtable_{{ version }}.tar.gz
  url:
    - https://cran.r-project.org/src/contrib/huxtable_{{ version }}.tar.gz
    - https://cran.r-project.org/src/contrib/Archive/huxtable/huxtable_{{ version }}.tar.gz
  sha256: fe8db4bdf57a243b42340b5d0c7db23f2aae1cea406e7c5bb6101a96ba49656d

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

requirements:
  build:
    - r-base
    - r-assertthat
    - r-dplyr
    - r-glue
    - r-htmltools
    - r-knitr
    - r-lazyeval
    - r-rmarkdown
    - r-stringr
    - r-tibble
    - r-tidyselect

  run:
    - r-base
    - r-assertthat
    - r-dplyr
    - r-glue
    - r-htmltools
    - r-knitr
    - r-lazyeval
    - r-rmarkdown
    - r-stringr
    - r-tibble
    - r-tidyselect

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

about:
  home: https://hughjonesd.github.io/huxtable
  license: MIT
  summary: Like 'xtable', creates styled tables. Export to HTML, LaTeX, 'Word',  'Excel', 'PowerPoint'
    and other formats. Simple, modern interface to manipulate  borders, size, position,
    captions, colours, text styles and number formatting. Includes  a 'huxreg' function
    for creation of regression tables, and 'quick_*'  one-liners to print data to a
    new document.
  license_family: MIT

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