git.recursive: Recursively extract the symbolic links to all github...

Description Usage Arguments Details Value Examples

View source: R/github_recursive.R

Description

git.recursive

Usage

1
git.recursive(x, filter_pat = NULL)

Arguments

x

The combo of username/repo or full folder path to a github repository.

filter_pat

A pattern to filter the returned data frame for subsetting

Details

This function takes a either a combination of a username/repo, or a full path to a rop folder and recurively retreives the file information.

Value

A data frame with 7 observations on the following 5 variables.

file_name

characterThe basename of the file.

file_link

characterFull path to the file.

file_type

characterFile extension or file-type.

folder

character The directory path-folder that contains the file.

raw

characterA full path to the raw github file, which can be downloaded as if it were a cdn.

Examples

1
2
3
4
5
6
had_xml2 <- git.recursive('hadley/xml2')
dim(had_xml2)

# get the first R file from the Ropensci Magick repo
git.recursive('ropensci/magick', filter_pat = "\\.R$") %>%
 slice(1) %>% .$raw

CarlBoneri/roxydoc2 documentation built on Nov. 6, 2019, 8:01 a.m.