43 lines
1.1 KiB
R
43 lines
1.1 KiB
R
### Lists packages without any successful binaries, i.e. pkgs for which all builds errored (per platform & arch)
|
|
library(DBI)
|
|
library(dplyr)
|
|
con <- DBI::dbConnect(
|
|
RPostgres::Postgres(),
|
|
dbname = "build_metadata",
|
|
host = "r-binaries.devxy.io",
|
|
port = 15432,
|
|
user = "r_binaries",
|
|
password = Sys.getenv("PGPASS"),
|
|
sslmode = "require"
|
|
)
|
|
|
|
cran_pkgs <- tools::CRAN_package_db() |>
|
|
filter(`Date/Publication` <= "2024-12-02") |>
|
|
pull(Package)
|
|
|
|
data <- dbGetQuery(
|
|
con,
|
|
"SELECT name,platform,arch,removed,error_occurred FROM single_builds;"
|
|
)
|
|
|
|
pkgs <- data |>
|
|
filter(platform == "alpine-320", arch == "arm64") |>
|
|
filter(removed == FALSE) |>
|
|
filter(error_occurred == FALSE) |>
|
|
distinct(name) |>
|
|
pull(name)
|
|
|
|
pkgs = setdiff(cran_pkgs, pkgs)
|
|
# Format, remove line breaks, and print as a single line
|
|
formatted_pkgs <- gsub(
|
|
'"',
|
|
"'",
|
|
capture.output(dput(as.character(na.omit(pkgs[1:900]))))
|
|
)
|
|
|
|
formatted_pkgs_one_line <- paste(formatted_pkgs, collapse = " ")
|
|
|
|
cat(formatted_pkgs_one_line, "\n", sep = "")
|
|
length(pkgs)
|
|
|
|
clipr::write_clip(formatted_pkgs_one_line)
|