Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

align code with software review repo #839

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 0 additions & 7 deletions preface.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,6 @@ This book is a living document.
You can view updates to our best practices and policies via the [release notes](#booknews).
You can cite this book using [its Zenodo metadata and DOI](https://doi.org/10.5281/zenodo.2553043).

```{r}
#| echo: false
#| results: 'asis'
#| warning: false
source(file.path("scripts", "airtable-get-reviewers.R"), local = knitr::knit_global())
```

_If you want to contribute to this book (suggestions, corrections) please refer to [the GitHub repository](https://github.com/ropensci/dev_guide) in particular [the contributing guidelines](https://github.com/ropensci/dev_guide#contributing). Thanks!_

_We are thankful for all authors, reviewers and guest editors for helping us improve the system and this guide over the years. Thanks also to the following persons who made contributions to this guide and its previous incarnations: `r readLines("thanks.md")` Please tell us if we forgot to acknowledge your contribution!_
Expand Down
7 changes: 0 additions & 7 deletions preface.es.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,6 @@ Este libro es un documento vivo.
Puedes ver las actualizaciones de nuestras buenas prácticas y políticas a través de las [notas de cada versión](#booknews).
Puedes citar este libro utilizando [sus metadatos de Zenodo y su DOI](https://doi.org/10.5281/zenodo.2553043).

```{r}
#| echo: false
#| results: 'asis'
#| warning: false
source(file.path("scripts", "airtable-get-reviewers.R"), local = knitr::knit_global())
```

*Si quieres contribuir sugerencias o correcciones a este libro, visita [el repositorio de GitHub](https://github.com/ropensci/dev_guide) y, en particular, [la guía de contribución](https://github.com/ropensci/dev_guide#contributing). ¡Gracias!*

*Agradecemos a quienes crean, mantienen, revisan y editan paquetes por ayudarnos a mejorar el sistema y esta guía a lo largo de los años. Gracias también a las siguientes personas que han contribuido a esta guía y a sus versiones anteriores: `r readLines("thanks.md")`. Por favor, avísanos si nos olvidamos de reconocer tu contribución.*
Expand Down
61 changes: 61 additions & 0 deletions scripts/airtable-get-data.R
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
## setup ----

if (Sys.getenv("AIRTABLE_API_KEY") == ""){
Sys.setenv(AIRTABLE_API_KEY = params$AIRTABLE_API_KEY)
}
if (Sys.getenv("AIRTABLE_ID") == ""){
Sys.setenv(AIRTABLE_ID = params$AIRTABLE_ID)
}

## all reviewers ----
at_rev <- airtabler::airtable(base = Sys.getenv("AIRTABLE_ID"),
table = "reviewers-prod")
reviewers <- at_rev$`reviewers-prod`$select_all()

## eic ----

at_eic <- airtabler::airtable(base = Sys.getenv("AIRTABLE_ID"),
table = "editor-in-chief-rotation")
eic <- at_eic$`editor-in-chief-rotation`$select_all()

eic$period_start <- as.Date(eic$period_start)
eic$period_end <- as.Date(eic$period_end)
today <- Sys.Date ()
eic_now <- eic [which (eic$period_start <= today & eic$period_end >= today), ]
eic_name <- eic_now$acting_eic_name [[1]]
eic_id <- eic_now$acting_eic
eic_in_rev_table <- which(reviewers$id == eic_id)
eic_github <- reviewers$github[eic_in_rev_table]

## guest editors ----

at_guest <- airtabler::airtable(base = "app8dssb6a7PG6Vwj",
table = "guest-editors")


editor_index_all <- purrr::map_lgl(reviewers$editor, ~!is.null(.))
editors_all <- reviewers[which(editor_index_all), c("name", "github", "Affiliation", "editor")]
editors_all <- editors_all [which(!editors_all$name == eic_name), ]
last_names <- humaniformat::last_name(trimws(editors_all$name))
editors_all <- editors_all[order(last_names), ]

editors_past <- editors_all[grep("Emeritus", editors_all$editor), ]
editors <- editors_all[which(!editors_all$name %in% editors_past$name), ]

guest_editors <- at_guest$`guest-editors`$select_all()

guest_editors <- airtabler::airtable(base = "app8dssb6a7PG6Vwj",
table = "guest-editors")
guest_editors <- guest_editors$`guest-editors`$select_all(fields = list("name", "github"))
guest_editors <- guest_editors[!(guest_editors$name %in% c(editors$name, "???")), ]
last_names <- humaniformat::last_name(trimws(guest_editors$name))
guest_editors <- guest_editors[order(last_names), ]

## reviewers that are not editors ----

reviewers <- reviewers[purrr::map_lgl(reviewers$reviews,
~!is.null(.)) &
!(reviewers$name %in% c(editors_all$name, "???")), ]
last_names <- humaniformat::last_name(trimws(reviewers$name))
reviewers <- reviewers[order(last_names), ]
reviewers$name[is.na(reviewers$name)] <- reviewers$github[is.na(reviewers$name)]
20 changes: 12 additions & 8 deletions scripts/airtable-get-editors.R
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
guest_editors <- airtabler::airtable(base = "app8dssb6a7PG6Vwj",
table = "guest-editors")
guest_editors <- guest_editors$`guest-editors`$select_all(fields = list("name", "github"))
guest_editors <- guest_editors[!(guest_editors$name %in% c(editors, "???")), ]
# get last names
last_names <- humaniformat::last_name(trimws(guest_editors$name))
guest_editors <- guest_editors[order(last_names), ]
cat(paste0("[", guest_editors$name, "](https://github.com/", guest_editors$github, ")", collapse = " \U00B7 "))
gen_ed_out <- function(ed_dat) {
if (!"Affiliation" %in% names(ed_dat)) {
ed_dat$Affiliation <- NA_character_
}
out <- gsub("(,\\sNA|\\s);", ";", paste0(
"- [", ed_dat$name, "](https://github.com/", ed_dat$github, "), ",
ed_dat$Affiliation, ";\n"))
out[length(out)] <- gsub(";\\n$", ".\n", out[length(out)])
return(out)
}

cat(gen_ed_out(editors), sep = "")
6 changes: 6 additions & 0 deletions scripts/airtable-get-eic.R
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
out <- paste0(
"We rotate our Editor-in-Chief, generally every three months. ",
"Our current Editor-in-Chief is [", eic_name, "](https://github.com/",
eic_github, ").\n"
)
cat(out, sep = "")
1 change: 1 addition & 0 deletions scripts/airtable-get-guest-editors.R
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
cat(paste0("[", guest_editors$name, "](https://github.com/", guest_editors$github, ")", collapse = " \U00B7 "))
13 changes: 1 addition & 12 deletions scripts/airtable-get-reviewers.R
Original file line number Diff line number Diff line change
@@ -1,12 +1 @@
reviewers <- airtabler::airtable(base = "app8dssb6a7PG6Vwj",
table = "reviewers-prod")
reviewers <- reviewers$`reviewers-prod`$select_all(fields = list("reviews", "editor", "name", "github"))
editors <- reviewers[lengths(reviewers$editor) > 0,][["name"]]
reviewers <- reviewers[purrr::map_lgl(reviewers$reviews,
~!is.null(.)) &
!(reviewers$name %in% c(editors, "???")), ]
# get last names
last_names <- humaniformat::last_name(trimws(reviewers$name))
reviewers <- reviewers[order(last_names), ]
reviewers$name[is.na(reviewers$name)] <- reviewers$github[is.na(reviewers$name)]
cat(paste0("[", reviewers$name, "](https://github.com/", reviewers$github, ")", collapse = " \U00B7 "))
cat(paste0("[", reviewers$name, "](https://github.com/", reviewers$github, ")", collapse = " \U00B7 "))
45 changes: 34 additions & 11 deletions softwarereview_intro.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -49,38 +49,61 @@ Furthermore, authors and reviewers have the ability to contact privately the edi

## Editors and reviewers {#editors-and-reviewers}

### Associate editors {#associateditors}

rOpenSci's Software Peer Review process is run by:
rOpenSci's Software Peer Review process is run by our team of dedicated editors and reviewers.
Information on the current team, and the current status of software peer review, can be seen on our [interactive dashboard](https://ropensci-review-tools.github.io/dashboard/).

```{r}
#| child: "associate-editors.md"
#| echo: false
#| results: 'asis'
source(file.path("scripts", "airtable-get-data.R"), local = knitr::knit_global())

```

### Reviewers {#reviewers}

We are grateful to the following individuals who have offered up their time and expertise to review packages submitted to rOpenSci.
### Editor-in-Chief

```{r}
#| echo: false
source(file.path("scripts", "airtable-access.R"), local = knitr::knit_global())
#| results: 'asis'
source(file.path("scripts", "airtable-get-eic.R"), local = knitr::knit_global())

```


### Editorial team


Our current team of editors for software peer-review includes:

```{r}
#| echo: false
#| results: 'asis'
#| eval: !expr has_airtable_access()
source(file.path("scripts", "airtable-get-reviewers.R"), local = knitr::knit_global())
source(file.path("scripts", "airtable-get-editors.R"), local = knitr::knit_global())

```

We are also grateful to the following individuals who have served as guest editors.
### Reviewers and former editors

We are grateful to the following individuals who have offered up their time and expertise to review packages submitted to rOpenSci.

```{r}
#| echo: false
#| results: 'asis'
#| eval: !expr has_airtable_access()
source(file.path("scripts", "airtable-get-editors.R"), local = knitr::knit_global())
source(file.path("scripts", "airtable-get-reviewers.R"), local = knitr::knit_global())

```

We are also grateful to the following individuals who have previously served as editors.

```{r editors_past, echo=FALSE, results='asis'}
cat(gen_ed_out(editors_past), sep = "")
```

And the following who have served as guest editors.

```{r guest-editors-out, echo=FALSE, results='asis'}
cat(gen_ed_out(guest_editors), sep = "")
```


49 changes: 36 additions & 13 deletions softwarereview_intro.es.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -67,38 +67,61 @@ Además, tanto quienes envían paquete y quienes los revisan tienen la posibilid

## Personas responsables de edición y revisión {#editors-and-reviewers}

### Equipo editorial asociado {#associateditors}

El proceso de revisión por pares del software de rOpenSci está dirigido por

```{r}
#| child: "associate-editors.md"
#| echo: false
#| results: 'asis'
source(file.path("scripts", "airtable-get-data.R"), local = knitr::knit_global())

```

### Equipo de revisión {#reviewers}

Agradecemos a las siguientes personas que han ofrecido su tiempo y experiencia para revisar los paquetes enviados a rOpenSci:
### Líder Editorial

```{r}
#| echo: false
source(file.path("scripts", "airtable-access.R"), local = knitr::knit_global())
#| results: 'asis'
out <- paste0(
"Cambiamos lideres editoriales, aproximadamente cada 3 meses. ",
"Hoy es [", eic_name, "](https://github.com/",
eic_github, ").\n"
)
cat(out, sep = "")

```


### Equipo editorial asociado

Nuestro equipo editorial asociado incluye:

```{r}
#| echo: false
#| results: 'asis'
#| eval: !expr has_airtable_access()
source(file.path("scripts", "airtable-get-reviewers.R"), local = knitr::knit_global())
source(file.path("scripts", "airtable-get-editors.R"), local = knitr::knit_global())

```

También agradecemos a las siguientes personas que han tomado el rol de edición de forma invitada:

### Revisión y edición invitada

Agradecemos a las siguientes personas, quienes ofrecieron su tiempo y experiencia para revisar paquetes enviados a rOpenSci:

```{r}
#| echo: false
#| results: 'asis'
#| eval: !expr has_airtable_access()
source(file.path("scripts", "airtable-get-editors.R"), local = knitr::knit_global())
source(file.path("scripts", "airtable-get-reviewers.R"), local = knitr::knit_global())

```

También agradecemos a las siguientes personas que tenian antes el rol de revisión.

```{r editors_past, echo=FALSE, results='asis'}
cat(gen_ed_out(editors_past), sep = "")
```


También agradecemos a las siguientes personas que tomaron el rol de edición de forma invitada.

```{r guest-editors-out, echo=FALSE, results='asis'}
cat(gen_ed_out(guest_editors), sep = "")
```
Loading