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

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

source:
  url:
    - {{ cran_mirror }}/src/contrib/qdapTools_{{ version }}.tar.gz
    - {{ cran_mirror }}/src/contrib/Archive/qdapTools/qdapTools_{{ version }}.tar.gz
  sha256: 16489e4e3865d51875673033e706c5e76077c007a1b204c0d0ca89768a954828

build:
  merge_build_host: True  # [win]
  number: 1
  rpaths:
    - lib/R/lib/
    - lib/

requirements:
  build:
    - {{posix}}zip               # [win]
  host:
    - r-base
    - r-rcurl
    - r-xml
    - r-chron
    - r-data.table >=1.9.6
  run:
    - r-base
    - r-rcurl
    - r-xml
    - r-chron
    - r-data.table >=1.9.6

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

about:
  home: http://trinker.github.com/qdapTools/
  license: GPL-2
  summary: A collection of tools associated with the 'qdap' package that may be useful outside
    of the context of text analysis.
  license_family: GPL2
  license_file: '{{ environ["PREFIX"] }}/lib/R/share/licenses/GPL-2'  # [unix]
  license_file: '{{ environ["PREFIX"] }}\R\share\licenses\GPL-2'  # [win]

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