Skip to content

Commit

Permalink
Add pos.it to acceptable shortlinks for use_course
Browse files Browse the repository at this point in the history
  • Loading branch information
melissavanbussel committed Aug 15, 2024
1 parent 792cdd0 commit 7204e1b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions R/course.R
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
#'
#' * GitHub repo spec: "OWNER/REPO". Equivalent to
#' `https://github.com/OWNER/REPO/DEFAULT_BRANCH.zip`.
#' * bit.ly or rstd.io shortlinks: "bit.ly/xxx-yyy-zzz" or "rstd.io/foofy".
#' * bit.ly, pos.it, or rstd.io shortlinks: "bit.ly/xxx-yyy-zzz", "pos.it/foofy" or "rstd.io/foofy".
#' The instructor must then arrange for the shortlink to point to a valid
#' download URL for the target ZIP file. The helper
#' [create_download_url()] helps to create such URLs for GitHub, DropBox,
Expand Down Expand Up @@ -492,7 +492,7 @@ normalize_url <- function(url) {
}

is_shortlink <- function(url) {
shortlink_hosts <- c("rstd\\.io", "bit\\.ly")
shortlink_hosts <- c("rstd\\.io", "bit\\.ly", "pos\\.it")
any(map_lgl(shortlink_hosts, grepl, x = url))
}

Expand Down
2 changes: 1 addition & 1 deletion man/zip-utils.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 7204e1b

Please sign in to comment.