path <- dir("man", pattern = "\\.Rd$", full.names = TRUE)
rd <- lapply(path, tools::parse_Rd, permissive = TRUE)
has_tag <- function(x, tag) {
tags <- unlist(lapply(x, attr, "Rd_tag"))
any(tags %in% paste0("\\", tag))
}
path[sapply(rd, \(x) !has_tag(x, "value"))]
path[sapply(rd, \(x) !has_tag(x, "examples"))]
Not sure where this should live.