Skip to content

Commit

Permalink
Include version in path to trigger redownload on update.
Browse files Browse the repository at this point in the history
  • Loading branch information
LTLA committed Apr 9, 2024
1 parent c1f8066 commit a513de5
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions R/startGobbler.R
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,13 @@ startGobbler <- function(staging=tempfile(), registry=tempfile()) {
stop("unsupported architecture '", sysmachine, "'")
}

desired <- sprintf("gobbler-%s-%s", os, arch)
version <- "0.2.0"
binary <- sprintf("gobbler-%s-%s", os, arch)
desired <- paste0(binary, "-", version)
exe <- file.path(cache, desired)

if (!file.exists(exe)) {
url <- paste0("https://github.com/ArtifactDB/gobbler/releases/download/0.2.0/", desired)
url <- paste0("https://github.com/ArtifactDB/gobbler/releases/download/", version, "/", binary)
tmp <- tempfile()
if (download.file(url, tmp)) {
stop("failed to download the Gobbler binary")
Expand Down

0 comments on commit a513de5

Please sign in to comment.