plot(1:10)
Created on 2018-09-28 by the reprex package (v0.2.1)
``` r | |
library("magrittr") | |
homogeneize <- function(path){ | |
path %>% | |
readLines(encoding = "UTF-8") %>% | |
blogdown:::split_yaml_body() %>% | |
.$body %>% | |
commonmark::markdown_xml(extensions = TRUE) %>% | |
xml2::read_xml() -> post_xml | |
plot(1:10)
Created on 2018-09-28 by the reprex package (v0.2.1)
gistr |
gistr |
plot(1:10)
Created on 2018-09-29 by the reprex package (v0.2.1)
{ | |
"packages": [ | |
{ | |
"name": "auk", | |
"description": "eBird Data Extraction and Processing in R", | |
"details": "Extract and process bird sightings records from eBird \n (<http://ebird.org>), an online tool for recording bird observations. \n Public access to the full eBird database is via the eBird Basic Dataset \n (EBD; see <http://ebird.org/ebird/data/download> for access), a downloadable \n text file. This package is an interface to AWK for extracting data from the \n EBD based on taxonomic, spatial, or temporal filters, to produce a \n manageable file size that can be imported into R.", | |
"maintainer": "Matthew Strimas-Mackey", | |
"keywords": "dataset, ebird", | |
"github": "https://github.com/CornellLabofOrnithology/auk", | |
"status": { |
repos <- ghrecipes::get_repos("ropensci") | |
repos <- dplyr::mutate(repos, | |
name = stringr::str_remove(name, | |
"ropensci\\/")) | |
# archived | |
repos <- dplyr::filter(repos, !is_archived) | |
# are packages | |
repos$is_pkg <- purrr::map_lgl(repos$name, |
docs <- gh::gh('/users/ropensci-docs/repos?per_page=100', .limit = 1000) | |
repos <- ghrecipes::get_repos("ropensci") | |
repos2 <- ghrecipes::get_repos("ropenscilabs") | |
repos <- dplyr::bind_rows(repos[, "name"], repos2[, "name"]) | |
docs <- tibble::tibble(name = purrr::map_chr(docs, "name")) | |
repos <- tidyr::separate(repos, name, "/", into = c("org", "name")) | |
docs <- dplyr::left_join(docs, repos, by = "name") | |
docs <- docs[!is.na(docs$org),] | |
I hereby claim:
To claim this, I am signing this object:
path <- #path to pkg | |
scripts <- fs::dir_ls(file.path(path, "R")) | |
parse_one <- function(filename) { | |
filename |> | |
brio::read_lines() |> | |
purrr::discard(function(x) grepl("^#'", x)) |> | |
glue::glue_collapse(sep = "\n") |> | |
downlit::highlight(classes = downlit::classes_pandoc(), code = TRUE, pre = "bla") |> | |
xml2::read_html() |> |