fix: add missing / for JULIAUP_SERVER URL
For server url "https://myserver.com/julia-releases`, an extra backslash is
required so that `join` does not drop the "julia-release" prefix.
This fixes usage such as:
JULIAUP_SERVER=https://mirrors.bfsu.edu.cn/julia-releases juliaup add 1.7.2
@@ -5,7 +5,7 @@ use url::Url;
pub fn get_juliaserver_base_url() -> Result<Url> {
let base_url = if let Ok(val) = std::env::var("JULIAUP_SERVER") {
- val
+ if val.ends_with("/") {val} else {format!("{}/", val)}
} else {
"https://julialang-s3.julialang.org".to_string()
};
