Welcome to the pkgnet Gallery Repository!
Please visit the pkgnet website to view the gallery. See below for how to contribute.
To create the exhibit with one command, use create_exhibit.R
It creates both the report and image and saves them in an exhibit folder. Use it right from the terminal via Rscript.
$ Rscript -e 'install.packages("pkgnet")' # if necessary
$ git clone https://github.com/uptake/pkgnet-gallery.git
$ cd pkgnet-gallery
$ Rscript create_exhibit.R -o exhibits <package name>
Optionally, if you have the R package downloaded locally, you can create an exhibit with code coverage information.
$ Rscript create_exhibit.R -o exhibits -p <path to package> <package name>
See the help documentation for more information:
$ Rscript create_exhibit.R -h
If you would like to host your examples on this repository, include their addition to the exhibits
folder in your pull request.
If you have the means and desire to host your exhibits yourself, you are welcome to do that.
Add your exhibit to vignettes/pkgnet-gallery.Rmd
. Find the line that says
### ADD NEW EXHIBITS ABOVE THIS LINE ###
and then add a new entry to the list above that line for your package. (Note the leading comma---you shouldn't need to touch any other lines.)
, list(
package_name = "[Your Package Name]"
, report_url = "[URL to your package report]"
, image_url = "[URL to your image]"
)
OPTIONAL: If you have the knitr and glue packages installed, you should be able to test that everything runs through correctly by hitting "Knit" if you're using RStudio.
There are a few reasons:
- We would like to enable gallery updates more often than CRAN version updates.
- We would like to keep the pkgnet website in line with the last stable version of
pkgnet
(i.e. the CRAN version). - We would like to keep the pkgnet github repository small in size.
By having the gallery content hosted here, we achieve all three of these things.
We want to make the transition from the main pkgnet website to the gallery page within that website as seamless as possible. To do so, we create the gallery page with the same R package, pkgdown, that we use to create the main page with very similar configuration files. Since creating a section of a website outside of the R package directory is not standard functionality for pkgdown, we replicate a few files and folder structures pkgdown expects here.
Most likely. We've love for you to submit your ideas on the issues page (preferably on the main pkgnet repository).