Skip to content
Merged
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
10 changes: 5 additions & 5 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
Type: Package
Package: r3admin
Title: R-Cubed Teaching Helper Functions.
Package: samwise
Title: The Trusty Sidekick for Managing the Rostools Workshops
Version: 0.0.1
Authors@R:
person("Luke", "Johnston", , "lwjohnst@gmail.com", role = c("aut", "cre"),
comment = c(ORCID = "0000-0003-4169-2616"))
Description: Contains functions to help with managing, running, and
developing the r-cubed courses.
developing the rostools workshops.
License: MIT + file LICENSE
URL: https://github.com/rostools/r3admin
BugReports: https://github.com/rostools/r3admin/issues
URL: https://github.com/rostools/samwise
BugReports: https://github.com/rostools/samwise/issues
Depends:
R (>= 2.10)
Imports:
Expand Down
2 changes: 1 addition & 1 deletion R/admin.R
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ admin_create_planning_issue <- function(id) {
}

stamp_format <- lubridate::stamp_date("Mar. 1, 2021", quiet = TRUE)
template_path <- fs::path_package("r3admin", "templates", "planning-issue.md")
template_path <- fs::path_package("samwise", "templates", "planning-issue.md")
issue_description <- whisker::whisker.render(
# Skip the yaml metadata
readr::read_lines(template_path, skip = 7),
Expand Down
2 changes: 1 addition & 1 deletion R/checks.R
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ copy_emails_for_reminder <- function(data) {
}

copy_reminder_email_text <- function() {
fs::path_package("r3admin", "templates", "email-reminder.txt") %>%
fs::path_package("samwise", "templates", "email-reminder.txt") %>%
readr::read_lines() %>%
clipr::write_clip()
}
Expand Down
8 changes: 4 additions & 4 deletions R/common-files.R
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@
#'
copy_common_file <- function(file) {
file <- rlang::arg_match(file, fs::path_file(list_common_files()))
common_path <- fs::path_package("r3admin", "common", file)
common_path <- fs::path_package("samwise", "common", file)
header_text <- ""
if (file == "_variables.yml") {
header_text <- glue::glue(
"# Automatically created by `r3admin::copy_common_file('{file}')` on {lubridate::today()}."
"# Automatically created by `samwise::copy_common_file('{file}')` on {lubridate::today()}."
)
}
if (rprojroot::is_rstudio_project$testfun[[1]](".")) {
Expand All @@ -35,7 +35,7 @@ copy_common_file <- function(file) {
#' @examples
#' list_common_files("LICENSE.md")
list_common_files <- function(regexp = NULL) {
fs::path_package("r3admin", "common") |>
fs::path_package("samwise", "common") |>
fs::dir_ls(regexp = regexp)
}

Expand All @@ -49,7 +49,7 @@ list_common_files <- function(regexp = NULL) {
#' @examples
#' list_template_files("planning-issue.md")
list_template_files <- function(regexp = NULL) {
fs::path_package("r3admin", "templates") |>
fs::path_package("samwise", "templates") |>
fs::dir_ls(regexp = regexp)
}

Expand Down
2 changes: 1 addition & 1 deletion R/course-metadata.R
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
#' @examples
#' read_course_metadata()
read_course_metadata <- function() {
courses_path <- fs::path_package(package = "r3admin", "data", "courses.yaml")
courses_path <- fs::path_package(package = "samwise", "data", "courses.yaml")
yaml::read_yaml(courses_path)$course
}

Expand Down
4 changes: 2 additions & 2 deletions R/create-group-names.R
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ group_name_to_pdf <- function(group_name, output_dir) {
output_file <- stringr::str_replace_all(group_name, "\\.", "-")
output_file <- fs::path_ext_set(output_file, "pdf")
quarto::quarto_render(
input = fs::path_package("r3admin", "templates", "group-name-pdf.qmd"),
input = fs::path_package("samwise", "templates", "group-name-pdf.qmd"),
output_file = output_file,
execute_params = list(
team_name = group_name
Expand All @@ -73,7 +73,7 @@ group_names_as_strips_html <-
fs::dir_create(output_dir)
withr::local_dir(output_dir)
quarto::quarto_render(
input = fs::path_package("r3admin", "templates", "group-name-strips.qmd"),
input = fs::path_package("samwise", "templates", "group-name-strips.qmd"),
output_file = "group-names-to-cut.html",
execute_params = list(
name = group_names,
Expand Down
2 changes: 1 addition & 1 deletion R/post-course.R
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ create_course_tag <- function(start_date, message) {
#'
#' @examples
#' \dontrun{
#' fs::path_package("r3admin", "extdata", "_people.csv") %>% zen_creators_from_csv()
#' fs::path_package("samwise", "extdata", "_people.csv") %>% zen_creators_from_csv()
#' }
zen_creators_from_csv <- function(path) {
# TODO: Need to update this.
Expand Down
22 changes: 6 additions & 16 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,27 +1,17 @@

# r3admin: Helper functions for managing the r-cubed courses
# samwise: The trusty helper for managing the rostools workshops

<!-- badges: start -->
<!-- badges: end -->

The goal of r3admin is to help with teaching and general admin for developing
and running the r-cubed courses.
The goal of samwise is to help with teaching and general admin for developing
and running the rostools workshops.

## Installation

You can install the development version of r3admin like so:
You can install the development version of samwise like so:

``` r
# install.packages("remotes")
remotes::install_github("rostools/r3admin")
# install.packages("pak")
pak::pak("rostools/samwise")
```

## Example

This is a basic example which shows you how to solve a common problem:

``` r
library(r3admin)
## basic example code
```

8 changes: 4 additions & 4 deletions inst/templates/planning-issue.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ Before the course, please review the CONTRIBUTING guide, Code of Conduct, and th

## To do before course

Several of the below tasks (for the admin/lead instructor) can be done using the r3admin package.
Several of the below tasks (for the admin/lead instructor) can be done using the samwise package.

- [ ] {{tasks_start_date}}: (Optional) Send an calendar invite to registered participants with link to pre-course tasks and website.
- [ ] {{instructors_precourse_meeting}}: Send a calendar invite to instructors/helpers for course location (with planning issue link), dinner locations, and post-course debrief.
Expand All @@ -43,9 +43,9 @@ Several of the below tasks (for the admin/lead instructor) can be done using the
## To do after course

- [ ] Close the Google Forms feedback survey
- [ ] Update git tag and release it (`r3admin::create_course_tag()`)
- [ ] Update course metadata in `r3admin/data/courses.yaml`
- [ ] Update instructor/helper metadata in `r3admin/data/courses.yaml` and `r3admin/data/people/`
- [ ] Update git tag and release it (`samwise::create_course_tag()`)
- [ ] Update course metadata in `samwise/data/courses.yaml`
- [ ] Update instructor/helper metadata in `samwise/data/courses.yaml` and `samwise/data/people/`
- [ ] Update Zenodo DOI

## Other details
Expand Down
6 changes: 3 additions & 3 deletions justfile
Original file line number Diff line number Diff line change
Expand Up @@ -38,13 +38,13 @@ run-targets:
draft-reminder-email: run-targets
#!/usr/bin/Rscript
participant_emails <- get_participant_emails()
r3admin::create_draft_reminder_email()
samwise::create_draft_reminder_email()

# Create a GitHub issue for planning the next upcoming course
create-upcoming-planning-issue: build
#!/usr/bin/Rscript
r3admin::admin_create_planning_issue(
id = r3admin::get_upcoming_course()
samwise::admin_create_planning_issue(
id = samwise::get_upcoming_course()
)

# Create the PDF and HTML files used for putting people into the groups
Expand Down
File renamed without changes.