fixed config version of binaries depending on socks5 core configs

This commit is contained in:
Jędrzej Stuczyński
2023-06-14 16:44:01 +01:00
parent 31b7921c68
commit a76a51e823
4 changed files with 17 additions and 5 deletions
+5 -1
View File
@@ -70,7 +70,11 @@ impl NymConfigTemplate for Config {
impl Config {
pub fn new<S: AsRef<str>>(id: S, provider_mix_address: S) -> Self {
Config {
core: CoreConfig::new(id.as_ref(), provider_mix_address.as_ref()),
core: CoreConfig::new(
id.as_ref(),
env!("CARGO_PKG_VERSION"),
provider_mix_address.as_ref(),
),
storage_paths: SocksClientPaths::new_default(default_data_directory(id.as_ref())),
logging: Default::default(),
}
+2 -2
View File
@@ -27,9 +27,9 @@ pub struct Config {
}
impl Config {
pub fn new<S: Into<String>>(id: S, provider_mix_address: S) -> Self {
pub fn new<S: Into<String>>(id: S, version: S, provider_mix_address: S) -> Self {
Config {
base: BaseClientConfig::new(id.into(), env!("CARGO_PKG_VERSION").to_string()),
base: BaseClientConfig::new(id, version),
socks5: Socks5::new(provider_mix_address),
}
}
@@ -73,7 +73,11 @@ pub fn socks5_config_id_appended_with(gateway_id: &str) -> String {
impl Config {
pub fn new<S: AsRef<str>>(id: S, provider_mix_address: S) -> Self {
Config {
core: Socks5CoreConfig::new(id.as_ref(), provider_mix_address.as_ref()),
core: Socks5CoreConfig::new(
id.as_ref(),
env!("CARGO_PKG_VERSION"),
provider_mix_address.as_ref(),
),
storage_paths: NymConnectPaths::new_default(default_data_directory(id.as_ref())),
}
}
+5 -1
View File
@@ -67,7 +67,11 @@ impl Config {
S: AsRef<str>,
{
Config {
core: CoreConfig::new(id.as_ref(), provider_mix_address.as_ref()),
core: CoreConfig::new(
id.as_ref(),
env!("CARGO_PKG_VERSION"),
provider_mix_address.as_ref(),
),
storage_paths: storage_root.map(|storage_root| {
MobileSocksClientPaths::new_default(data_directory_from_root(
storage_root,