Created
September 16, 2015 10:11
-
-
Save jeroen/39a19b5a8f555caa876b to your computer and use it in GitHub Desktop.
Find CRAN packages with FORTRAN code
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Find all CRAN package with FORTRAN code | |
packages <- c() | |
base_url <- 'https://api.github.com/search/repositories?q=user:cran%20language:fortran' | |
for(page in 1:100){ | |
url <- paste0(base_url, "&page=", page) | |
cat("Reading", url, "\n") | |
repos <- jsonlite::fromJSON(url) | |
if(!length(repos$items)) | |
break | |
packages <- c(packages, repos$items$name) | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Thanks