this should be good for now

This commit is contained in:
lkoester
2024-04-22 16:56:49 +02:00
parent 1e867a51f5
commit 88d4384beb
3 changed files with 78 additions and 37 deletions

View File

@ -3,13 +3,12 @@ use num_enum::{IntoPrimitive, TryFromPrimitive};
use satrs::spacepackets::PacketId;
use satrs_mib::res_code::ResultU16Info;
use satrs_mib::resultcode;
use std::env;
use std::net::Ipv4Addr;
use std::path::{Path, PathBuf};
pub const STOP_FILE_NAME: &str = "stop-experiment";
pub const CONFIG_FILE_NAME: &str = "exp278.toml";
pub const HOME_FOLER_EXPERIMENT: &str = "/home/exp278";
pub const HOME_FOLDER_EXPERIMENT: &str = "/home/exp278";
pub const LOG_FOLDER: &str = "logs";
pub const OBSW_SERVER_ADDR: Ipv4Addr = Ipv4Addr::UNSPECIFIED;
@ -43,7 +42,7 @@ pub enum GroupId {
lazy_static! {
pub static ref HOME_PATH: PathBuf = {
let mut home_path = PathBuf::new();
let mut home_path_default = homedir::get_my_home().expect("Getting home dir from OS failed.").expect("No home dir found.");
let home_path_default = homedir::get_my_home().expect("Getting home dir from OS failed.").expect("No home dir found.");
home_path.push(if Path::new(HOME_FOLDER_EXPERIMENT).exists() {
HOME_FOLDER_EXPERIMENT