# Contributor: Viktor Drobot (aka dviktor) linux776 [at] gmail [dot] com
# Contributor: Pranav K Anupam <pranavanupam@yahoo.com>
# Contributor: Alex Branham <branham@utexas.edu>
_cranname=tidytext
_cranver=0.4.1
pkgname=r-${_cranname,,}
pkgver=${_cranver//[:-]/.}
pkgrel=1
pkgdesc="Functions and supporting data sets to allow conversion of text to and from tidy formats, and to switch seamlessly between tidy tools and existing text mining packages."
arch=(any)
url="https://cran.r-project.org/package=${_cranname}"
license=(MIT)
depends=('r>=2.10' r-cli r-dplyr r-generics r-janeaustenr r-lifecycle r-matrix r-methods r-purrr 'r-rlang>=0.4.10' r-stringr r-tibble r-tokenizers r-vctrs)
optdepends=(r-broom r-covr r-data.table r-ggplot2 r-hunspell r-knitr r-mallet r-nlp r-quanteda r-readr r-reshape2 r-rmarkdown r-scales r-stm r-stopwords 'r-testthat>=2.1.0' r-textdata r-tidyr r-tm r-topicmodels r-vdiffr r-wordcloud)
source=("https://cran.r-project.org/src/contrib/${_cranname}_${_cranver}.tar.gz")
sha256sums=('526750a2cc8ac7b65be1093f4c9186aa27f0a22f00023a6d6b3b878e1310c815')
build() {
R CMD INSTALL ${_cranname}_${_cranver}.tar.gz -l "${srcdir}"
}
package() {
install -dm0755 "${pkgdir}/usr/lib/R/library"
cp -a --no-preserve=ownership "${_cranname}" "${pkgdir}/usr/lib/R/library"
}