Move `rmarkdown` to`Suggests` field
Closed this issue · 3 comments
dipterix commented
I wonder if rmarkdown
can be in Suggests
field instead of Imports
in DESCRIPTION
, since has_pandoc
is the only place using rmarkdown. You can dynamically check if this package has been installed via
# old
has_pandoc <- function() {
return(rmarkdown::pandoc_available());
}
# suggest
has_pandoc <- function() {
if(system.file(package = "rmarkdown") == "") { return(FALSE) }
return(rmarkdown::pandoc_available());
}
I can create a PR if you like this idea.
dfsp-spirit commented
Yes, feel free to do that.
dipterix commented
@dfsp-spirit The PR #31 is ready. Also just to mention (in case), this edit complies with CRAN policy : )
dfsp-spirit commented
Thanks a lot, it's merged.
Just one minor thing: in this case it did not matter, but in general please do PRs against the develop
branch, not master
in the future.