I have a pkgdown
site in which I group a number of functions into categories in the reference .yml
file. I'm wondering if there is a way to put all of the functions which I didn't explicitly categorize into their own category. The only thought I had was to use the matches
function like so:
reference:
- title: "someCategory"
contents:
- myFunction
- title: "other"
contents:
- matches(".*")
But this puts myFunction
in both the "someCategory" and "other" categories. What I'd like to do is match all functions which aren't in a category.
Thanks!
If you don't mind running a function to update your yaml, running this from the root of your package should work (use "overwrite = FALSE" for testing: it will create a _pkgdown_new.yaml file.):
The function browses the current .yaml file and finds the currently missing functions. If any are found, they are added to the "Others" section of the .yaml (which is automatically created if not already present).
I did a quick test and it seems to work properly.
HTH !