Replies: 2 comments
-
Thanks for letting me know! I'll think about some way to bypass the check perhaps.... |
Beta Was this translation helpful? Give feedback.
0 replies
-
For now, overwriting the get_latest<- function (r_version)
{
is_online <- TRUE
stopifnot(`r_version has to be a character.` = is.character(r_version))
if (nchar(r_version) == 40) {
return(r_version)
}
else if (!(r_version %in% c("bioc-devel", "r-devel-bioc-devel",
"r-devel", "frozen-edge", "bleeding-edge", "latest-upstream")) &&
all(r_version > base::Filter(function(x) ("latest-upstream" !=
x), available_r()))) {
stop("The provided R version is too recent,\nand not yet included in `nixpkgs`.\n",
"You can list available versions using `available_r()`.\n",
"You can also use a date, see `available_dates()`.\n",
"You can also directly provide a commit, but you need \n",
"to make sure it points to the right repo used by `rix()`.\n",
"You can also use 'r-devel', 'r-devel-bioc-devel', bioc-devel'\n",
"'bleeding-edge' and 'frozen-edge'.")
}
else if (!(r_version %in% c("r-devel-bioc-devel", "r-devel",
"bioc-devel", "bleeding-edge", "frozen-edge", available_r()))) {
stop("The provided R version is too recent,\nand not yet included in `nixpkgs`.\n",
"You can list available versions using `available_r()`.\n",
"You can also use a date, see `available_dates()`.\n",
"You can also directly provide a commit, but you need \n",
"to make sure it points to the right repo used by `rix()`.\n",
"You can also use 'r-devel', 'r-devel-bioc-devel', bioc-devel'\n",
"'bleeding-edge' and 'frozen-edge'.")
}
else if (!is_online) {
stop("ERROR! You don't seem to be connected to the internet.")
}
else if (r_version == "bleeding-edge") {
latest_commit <- "refs/heads/r-daily"
}
else if (r_version == "bioc-devel") {
latest_commit <- "refs/heads/r-bioc-devel"
}
else if (r_version == "r-devel") {
latest_commit <- "refs/heads/r-devel"
}
else if (r_version == "r-devel-bioc-devel") {
latest_commit <- "refs/heads/r-devel-bioc-devel"
}
else {
latest_commit <- rix:::get_right_commit(r_version)
}
latest_commit
}
assignInNamespace("get_latest",get_latest,ns="rix") |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I am experience issues using rix at my workstation due to
curl::has_internet()
not reliably detecting internet access. See jeroen/curl#401. Since this is an issue in a dependency and not directly with rix, I've decided to raise the point here initially as a discussion instead of an issue.Beta Was this translation helpful? Give feedback.
All reactions