{% set version = '1.0.0' %}

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

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

source:
  fn: janitor_{{ version }}.tar.gz
  url:
    - https://cran.r-project.org/src/contrib/janitor_{{ version }}.tar.gz
    - https://cran.r-project.org/src/contrib/Archive/janitor/janitor_{{ version }}.tar.gz
  sha256: e9a8ed543b637a073083addf366630b663253bdd12da5488e8de9f8934c2d560

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

requirements:
  build:
    - r-base
    - r-dplyr >=0.7.0
    - r-magrittr
    - r-purrr
    - r-rlang
    - r-snakecase >=0.9.0
    - r-tidyr >=0.7.0

  run:
    - r-base
    - r-dplyr >=0.7.0
    - r-magrittr
    - r-purrr
    - r-rlang
    - r-snakecase >=0.9.0
    - r-tidyr >=0.7.0

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

about:
  home: https://github.com/sfirke/janitor
  license: MIT
  summary: 'The main janitor functions can: perfectly format data.frame column names; provide
    quick counts of variable combinations (i.e., frequency tables and crosstabs); and isolate
    duplicate records. Other janitor functions nicely format the tabulation results. These
    tabulate-and-report functions approximate popular features of SPSS and Microsoft Excel.
    This package follows the principles of the "tidyverse" and works well with the pipe
    function %>%. janitor was built with beginning-to-intermediate R users in mind and is
    optimized for user-friendliness. Advanced R users can already do everything covered here,
    but with janitor they can do it faster and save their thinking for the fun stuff.'
  license_family: MIT

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