From 08d5a9c10f76dde5d7cfb4da4e46ff2ac1bfa718 Mon Sep 17 00:00:00 2001 From: mrustl Date: Tue, 13 Jul 2021 00:47:28 +0200 Subject: [PATCH 1/5] Add `Released_on_R-Universe` and prepare v0.3.0 (based on `kwb.pkgbuild::use_badge_runiverse()` for linking to [https://kwb-r.r-universe.dev](https://kwb-r.r-universe.dev)) if package is available --- DESCRIPTION | 9 ++++++++- NEWS.md | 6 ++++++ R/prepare_status_rpackages.R | 7 +++++++ README.md | 19 +++++++++++++++++-- index.md | 24 +++++++++++++++++++----- 5 files changed, 57 insertions(+), 8 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index 9aaa9b7..b167559 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,12 +1,19 @@ Package: kwb.pkgstatus Title: R package for checking KWB package status -Version: 0.2.0 +Version: 0.3.0 Authors@R: c(person(given = "Michael", family = "Rustler", role = c("aut", "cre"), email = "michael.rustler@kompetenz-wasser.de", comment = c(ORCID = "0000-0003-0647-7726")), + person(given = "Hauke", + family = "Sonnenberg", + role = "ctb", + email = "hauke.sonnenberg@kompetenz-wasser.de", + comment = c(ORCID = "0000-0001-9134-2871")), + person(given = "FAKIN", + role = "fnd"), person(given = "Kompetenzzentrum Wasser Berlin gGmbH (KWB)", role = "cph")) Description: R package for checking KWB package status (e.g. diff --git a/NEWS.md b/NEWS.md index 4f08949..3c3b5b2 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,3 +1,9 @@ +# [kwb.pkgstatus 0.3.0](https://github.com/KWB-R/kwb.pkgstatus/releases/tag/v0.3.0)2021-07-13 + +* Add `Released_on_R-Universe` (based on `kwb.pkgbuild::use_badge_runiverse()` +for linking to [https://kwb-r.r-universe.dev](https://kwb-r.r-universe.dev)) +if package is available + # [kwb.pkgstatus 0.2.0](https://github.com/KWB-R/kwb.pkgstatus/releases/tag/v0.2.0)2021-02-23 * Adapt status overview (use Github Actions workflow!) diff --git a/R/prepare_status_rpackages.R b/R/prepare_status_rpackages.R index 252eedf..4cb0b02 100644 --- a/R/prepare_status_rpackages.R +++ b/R/prepare_status_rpackages.R @@ -76,6 +76,12 @@ build_doc_release <- as.vector(sapply(repo_infos$name, function(repo) { build_doc_dev <- as.vector(sapply(repo_infos$name, function(repo) { kwb.pkgbuild::use_badge_ghactions_pkgdown(repo, branch = "dev") })) + +badge_runiverse <- as.vector(sapply(repo_infos$name, function(repo) { + kwb.pkgbuild::use_badge_runiverse(repo) +})) + +sapply(repo_infos$name, kwb.pkgbuild::use_badge_runiverse) meta_info <- data.frame(License_Badge = badge_license(repo_infos$license_key), Dependencies = badge_dependencies(repo_infos$name), @@ -84,6 +90,7 @@ Build_Pkg_Release = build_pkg_release, Build_Pkg_Dev = build_pkg_dev, Build_Doc_Release = build_doc_release, Build_Doc_Dev = build_doc_dev, +Released_on_R-Universe = badge_runiverse, ### Avoid issue with CRAN R packages badges ### (no problem if PANDOC version >= 2.2.1) ### https://github.com/rstudio/rmarkdown/issues/228 diff --git a/README.md b/README.md index 230ba93..5f3aa6e 100644 --- a/README.md +++ b/README.md @@ -3,15 +3,30 @@ [![codecov](https://codecov.io/github/KWB-R/kwb.pkgstatus/branch/master/graphs/badge.svg)](https://codecov.io/github/KWB-R/kwb.pkgstatus) [![Project Status](https://img.shields.io/badge/lifecycle-experimental-orange.svg)](https://www.tidyverse.org/lifecycle/#experimental) [![CRAN_Status_Badge](https://www.r-pkg.org/badges/version/kwb.pkgstatus)]() +[![R-Universe_Status_Badge](https://kwb-r.r-universe.dev/badges/kwb.pkgstatus)](https://kwb-r.r-universe.dev/) # kwb.pkgstatus -R package for checking KWB package status (e.g. generating https://kwb-r.github.io/status) +R package for checking KWB package status (e.g. +generating https://kwb-r.github.io/status). ## Installation +For details on how to install KWB-R packages checkout our [installation tutorial](https://kwb-r.github.io/kwb.pkgbuild/articles/install.html). + ```r -#install.packages("remotes", repos = "https://cloud.r-project.org") +### Optionally: specify GitHub Personal Access Token (GITHUB_PAT) +### See here why this might be important for you: +### https://kwb-r.github.io/kwb.pkgbuild/articles/install.html#set-your-github_pat + +# Sys.setenv(GITHUB_PAT = "mysecret_access_token") + +# Install package "remotes" from CRAN +if (! require("remotes")) { + install.packages("remotes", repos = "https://cloud.r-project.org") +} + +# Install KWB package 'kwb.pkgstatus' from GitHub remotes::install_github("KWB-R/kwb.pkgstatus") ``` diff --git a/index.md b/index.md index 65ce833..80be9b9 100644 --- a/index.md +++ b/index.md @@ -1,15 +1,29 @@ [![R-CMD-check](https://github.com/KWB-R/kwb.pkgstatus/workflows/R-CMD-check/badge.svg)](https://github.com/KWB-R/kwb.pkgstatus/actions?query=workflow%3AR-CMD-check) [![pkgdown](https://github.com/KWB-R/kwb.pkgstatus/workflows/pkgdown/badge.svg)](https://github.com/KWB-R/kwb.pkgstatus/actions?query=workflow%3Apkgdown) -[![codecov](https://codecov.io/github/KWB-R/kwb.pkgstatus/branch/master/graphs/badge.svg)](https://codecov.io/github/KWB-R/kwb.pkgstatus) +[![codecov](https://codecov.io/github/KWB-R/kwb.pkgstatus/branch/main/graphs/badge.svg)](https://codecov.io/github/KWB-R/kwb.pkgstatus) [![Project Status](https://img.shields.io/badge/lifecycle-experimental-orange.svg)](https://www.tidyverse.org/lifecycle/#experimental) [![CRAN_Status_Badge](https://www.r-pkg.org/badges/version/kwb.pkgstatus)]() +[![R-Universe_Status_Badge](https://kwb-r.r-universe.dev/badges/kwb.pkgstatus)](https://kwb-r.r-universe.dev/) - -R package for checking KWB package status (e.g. generating https://kwb-r.github.io/status) +R package for checking KWB package status (e.g. +generating https://kwb-r.github.io/status). ## Installation +For details on how to install KWB-R packages checkout our [installation tutorial](https://kwb-r.github.io/kwb.pkgbuild/articles/install.html). + ```r -#install.packages("remotes", repos = "https://cloud.r-project.org") +### Optionally: specify GitHub Personal Access Token (GITHUB_PAT) +### See here why this might be important for you: +### https://kwb-r.github.io/kwb.pkgbuild/articles/install.html#set-your-github_pat + +# Sys.setenv(GITHUB_PAT = "mysecret_access_token") + +# Install package "remotes" from CRAN +if (! require("remotes")) { + install.packages("remotes", repos = "https://cloud.r-project.org") +} + +# Install KWB package 'kwb.pkgstatus' from GitHub remotes::install_github("KWB-R/kwb.pkgstatus") -``` \ No newline at end of file +``` From a5d3b77a53e8a2b70d8428d8b51c5f46c06c601e Mon Sep 17 00:00:00 2001 From: mrustl Date: Tue, 13 Jul 2021 00:48:06 +0200 Subject: [PATCH 2/5] Add project FAKIN as funder and @hsonne as ctb --- _pkgdown.yml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/_pkgdown.yml b/_pkgdown.yml index 5d8d9c8..033a7e3 100644 --- a/_pkgdown.yml +++ b/_pkgdown.yml @@ -1,8 +1,14 @@ authors: Michael Rustler: href: https://mrustl.de + Hauke Sonnenberg: + href: https://github.com/hsonne + FAKIN: + href: https://www.kompetenz-wasser.de/en/project/fakin/ + html: Kompetenzzentrum Wasser Berlin gGmbH (KWB): - href: http://www.kompetenz-wasser.de + href: https://www.kompetenz-wasser.de html: template: From 3e06febb907eff5bd6d5e3e4e982c3acb66a886d Mon Sep 17 00:00:00 2001 From: mrustl Date: Tue, 13 Jul 2021 01:06:00 +0200 Subject: [PATCH 3/5] Import function and fix column name --- NAMESPACE | 1 + R/prepare_status_rpackages.R | 6 +++--- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/NAMESPACE b/NAMESPACE index 5985921..8b12ac2 100644 --- a/NAMESPACE +++ b/NAMESPACE @@ -37,6 +37,7 @@ importFrom(httr,status_code) importFrom(jsonlite,fromJSON) importFrom(kwb.pkgbuild,use_badge_ghactions_pkgdown) importFrom(kwb.pkgbuild,use_badge_ghactions_rcmdcheck) +importFrom(kwb.pkgbuild,use_badge_runiverse) importFrom(lubridate,as_datetime) importFrom(magrittr,"%>%") importFrom(stringr,str_detect) diff --git a/R/prepare_status_rpackages.R b/R/prepare_status_rpackages.R index 4cb0b02..d05b72e 100644 --- a/R/prepare_status_rpackages.R +++ b/R/prepare_status_rpackages.R @@ -34,7 +34,8 @@ check_all_tokens_set <- function() { #' @param non_r_packages a character vector with repositories in KWB-R group that #' are not R packages (default: \code{get_non_r_packages}) #' @importFrom dplyr filter_ left_join -#' @importFrom kwb.pkgbuild use_badge_ghactions_rcmdcheck use_badge_ghactions_pkgdown +#' @importFrom kwb.pkgbuild use_badge_ghactions_rcmdcheck use_badge_ghactions_pkgdown +#' use_badge_runiverse #' @importFrom utils read.csv #' @return data.frame with R package status information #' @export @@ -81,7 +82,6 @@ badge_runiverse <- as.vector(sapply(repo_infos$name, function(repo) { kwb.pkgbuild::use_badge_runiverse(repo) })) -sapply(repo_infos$name, kwb.pkgbuild::use_badge_runiverse) meta_info <- data.frame(License_Badge = badge_license(repo_infos$license_key), Dependencies = badge_dependencies(repo_infos$name), @@ -90,7 +90,7 @@ Build_Pkg_Release = build_pkg_release, Build_Pkg_Dev = build_pkg_dev, Build_Doc_Release = build_doc_release, Build_Doc_Dev = build_doc_dev, -Released_on_R-Universe = badge_runiverse, +`Released_on_R-Universe` = badge_runiverse, ### Avoid issue with CRAN R packages badges ### (no problem if PANDOC version >= 2.2.1) ### https://github.com/rstudio/rmarkdown/issues/228 From 2877aa1390617f4dfcee1307ec9ee096d162906e Mon Sep 17 00:00:00 2001 From: mrustl Date: Tue, 13 Jul 2021 01:10:18 +0200 Subject: [PATCH 4/5] Add "universe" to non R packages --- R/get_non_r_packages.R | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/R/get_non_r_packages.R b/R/get_non_r_packages.R index 1264b81..70bca68 100644 --- a/R/get_non_r_packages.R +++ b/R/get_non_r_packages.R @@ -11,6 +11,6 @@ get_non_r_packages <- function() { "fakin.blog", "fakin.doc", "fakin.scripts", "FolderRights", "flusshygiene", "HydroServerLite", "GeoSalz", "pathana", "pFromGrADS", "r-training", "support", "maxflow", "pubs", "riverPollution", "smart.control", - "sema.scripts", "spur", "status", "useR-2019", "wellma.scripts") + "sema.scripts", "spur", "status", "universe", "useR-2019", "wellma.scripts") } From fddd24e5fa4df771359734605001ee223fb2b0ad Mon Sep 17 00:00:00 2001 From: mrustl Date: Tue, 13 Jul 2021 01:14:47 +0200 Subject: [PATCH 5/5] Use latest "stable" version on master --- DESCRIPTION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/DESCRIPTION b/DESCRIPTION index b167559..14fe859 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -40,7 +40,7 @@ Suggests: VignetteBuilder: knitr Remotes: - github::kwb-r/kwb.pkgbuild@v0.1.7 + github::kwb-r/kwb.pkgbuild ByteCompile: true Encoding: UTF-8 LazyData: true