diff --git a/.github/workflows/build-collection.yml b/.github/workflows/build-collection.yml index 21dc4835..c78b33eb 100644 --- a/.github/workflows/build-collection.yml +++ b/.github/workflows/build-collection.yml @@ -69,7 +69,7 @@ jobs: Rscript --vanilla "scripts/query_collection.R" --git_pat "$GH_PAT" - name: Archive collection - uses: actions/upload-artifact@v2 + uses: actions/upload-artifact@v4.6.2 with: name: collection path: resources/collection.tsv diff --git a/.github/workflows/pull_request.yml b/.github/workflows/pull_request.yml index 4fc7638d..d5410d00 100644 --- a/.github/workflows/pull_request.yml +++ b/.github/workflows/pull_request.yml @@ -80,7 +80,7 @@ jobs: with: check_type: spelling error_min: 3 - gh_pat: secrets.GH_PAT + gh_pat: ${{ secrets.GH_PAT }} url-check: name: Check URLs @@ -90,7 +90,7 @@ jobs: with: check_type: urls error_min: 0 - gh_pat: secrets.GH_PAT + gh_pat: ${{ secrets.GH_PAT }} render-preview: name: Render preview diff --git a/resources/images/ITNlogo.png b/resources/images/ITNlogo.png new file mode 100644 index 00000000..0ade9343 Binary files /dev/null and b/resources/images/ITNlogo.png differ diff --git a/scripts/query_collection.R b/scripts/query_collection.R index 69e18b57..1a3caabc 100644 --- a/scripts/query_collection.R +++ b/scripts/query_collection.R @@ -56,7 +56,7 @@ for (page in 1:last){ jsonlite::fromJSON(httr::content(req, as = "text"), flatten = TRUE) message(paste("... Gathered", nrow(repo_dat$items), "repositories.")) - repo_dat$items$funding <- lapply(repo_dat$items$topics, function(x) x[x %in% c("anvil", "itn", "daseh", "gdscn", "hutch-course")]) + repo_dat$items$funding <- lapply(repo_dat$items$topics, function(x) x[x %in% c("anvil", "itn-course", "daseh", "gdscn", "hutch-course")]) repo_dat$items$funding <- lapply(repo_dat$items$funding, function(x) replace(x, rlang::is_empty(x), NA) ) repo_df <- diff --git a/scripts/render_collection.R b/scripts/render_collection.R index 207f7235..34271dd4 100644 --- a/scripts/render_collection.R +++ b/scripts/render_collection.R @@ -61,6 +61,14 @@ make_collection_table <- function(exclude = NULL, include = NULL, kable = FALSE) ), TRUE ~ funding )) %>% + mutate(funding = case_when( + stringr::str_detect(funding, "itn-course") ~ paste0( + funding, + '

ITN

' + ), + TRUE ~ funding + )) %>% + mutate(funding = gsub("^.*?