server: version repo url when not in dev mode

This commit is contained in:
nym21
2025-04-02 16:49:35 +02:00
parent c0144b99bf
commit 4c2da31bb3

View File

@@ -4,11 +4,9 @@
#![doc = "```"] #![doc = "```"]
use std::{ use std::{
collections::BTreeMap,
fs, fs,
io::Cursor, io::Cursor,
path::{Path, PathBuf}, path::{Path, PathBuf},
sync::Arc,
time::Instant, time::Instant,
}; };
@@ -70,9 +68,10 @@ impl Server {
if !fs::exists(&downloaded_websites_path)? { if !fs::exists(&downloaded_websites_path)? {
info!("Downloading websites from Github..."); info!("Downloading websites from Github...");
// TODO: Need to download versioned, main is only for testing let url = format!(
let url = "https://github.com/bitcoinresearchkit/brk/archive/refs/tags/v{}.zip",
"https://github.com/bitcoinresearchkit/brk/archive/refs/heads/main.zip"; env!("CARGO_PKG_VERSION")
);
let response = minreq::get(url).send()?; let response = minreq::get(url).send()?;
let bytes = response.as_bytes(); let bytes = response.as_bytes();