ThinkR-open / attachment

Tools to deal with dependencies in scripts, Rmd and packages
https://thinkr-open.github.io/attachment/
Other
108 stars 13 forks source link

Find package used in `r ` #29

Closed ColinFay closed 3 years ago

ColinFay commented 3 years ago

If I have an Rmd with

`r pkg::fun()`

{attachment} won't be able to find it.

> x <- tempfile(fileext = ".Rmd")
> file.create(x)
[1] TRUE
> write("`r dplyr::select(iris, Species)`", x)
> readLines(x)
[1] "`r dplyr::select(iris, Species)`"
> attachment::att_from_rmd(x)
logical(0)

Would be nice to catch it.