From 34bbb1a00c4cdbdc8f2b60c4e90f11a87c920a45 Mon Sep 17 00:00:00 2001 From: Chevdor Date: Wed, 14 Jul 2021 12:59:30 +0200 Subject: [PATCH] fix: fix the retrieval of the latest tag --- lib/src/lib.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/src/lib.rs b/lib/src/lib.rs index 9771aef..59f296f 100644 --- a/lib/src/lib.rs +++ b/lib/src/lib.rs @@ -11,8 +11,8 @@ const CACHE_FILE: &str = "srtool-tag-latest.txt"; /// Fetch the latest image tag pub fn fetch_image_tag() -> Result { debug!("Fetching latest version from github"); - let url = "https://github.com/paritytech/srtool/-/raw/master/RUSTC_VERSION"; - let tag: String = ureq::get(url).set("Content-Type", "application/txt").call()?.into_string()?; + let url = "https://raw.githubusercontent.com/paritytech/srtool/master/RUSTC_VERSION"; + let tag: String = ureq::get(url).set("Content-Type", "application/txt").call()?.into_string()?.trim().to_string(); debug!("tag: {}", tag); Ok(tag) }