{% set version = "1.14" %}
{% set posix = 'm2-' if win else '' %}

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

source:
  url:
    - {{ cran_mirror }}/src/contrib/formatR_{{ version }}.tar.gz
    - {{ cran_mirror }}/src/contrib/Archive/formatR/formatR_{{ version }}.tar.gz
  sha256: 4ebaab2c3f8527871655246b62abd060bc75dae1cec7f962ca4752b8080f474c

build:
  number: 2
  noarch: generic
  rpaths:
    - lib/R/lib/
    - lib/

requirements:
  build:
    - {{ posix }}zip               # [win]
  host:
    - r-base
  run:
    - r-base

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

about:
  home: https://github.com/yihui/formatR
  license: GPL-2.0-or-later
  summary: Provides a function tidy_source() to format R source code. Spaces and indent will be added to the code automatically, and comments will be preserved under certain conditions, so that R code will be more human-readable and tidy. There is also a Shiny app as a user interface in this package (see tidy_app()).
  license_family: GPL
  license_file:
    - {{ environ["PREFIX"] }}/lib/R/share/licenses/GPL-3

extra:
  recipe-maintainers:
    - conda-forge/r

# Package: formatR
# Type: Package
# Title: Format R Code Automatically
# Version: 1.6
# Authors@R: c( person("Yihui", "Xie", role = c("aut", "cre"), email = "xie@yihui.name", comment = c(ORCID = "0000-0003-0645-5666")), person("Eugene", "Ha", role = "ctb"), person("Kohske", "Takahashi", role = "ctb"), person("Ed", "Lee", role = "ctb") )
# Description: Provides a function tidy_source() to format R source code. Spaces and indent will be added to the code automatically, and comments will be preserved under certain conditions, so that R code will be more human-readable and tidy. There is also a Shiny app as a user interface in this package (see tidy_app()).
# Depends: R (>= 3.0.2)
# Suggests: codetools, shiny, testit, rmarkdown, knitr
# License: GPL
# URL: https://github.com/yihui/formatR
# BugReports: https://github.com/yihui/formatR/issues
# VignetteBuilder: knitr
# RoxygenNote: 6.1.1
# Encoding: UTF-8
# NeedsCompilation: no
# Packaged: 2019-03-05 16:17:31 UTC; yihui
# Author: Yihui Xie [aut, cre] (<https://orcid.org/0000-0003-0645-5666>), Eugene Ha [ctb], Kohske Takahashi [ctb], Ed Lee [ctb]
# Maintainer: Yihui Xie <xie@yihui.name>
# Repository: CRAN
# Date/Publication: 2019-03-05 19:00:06 UTC
