adjusted base on execution path case of execution path is not working directory

This commit is contained in:
DustInDark
2022-06-23 21:16:26 +09:00
parent 3a493d6beb
commit ee934caf3c

View File

@@ -145,7 +145,10 @@ impl App {
.ok();
return;
}
// ワーキングディレクトリ以外からの実行の際にrules-configオプションの指定がないとエラーが発生することを防ぐための処理
if configs::CONFIG.read().unwrap().args.config.to_str().unwrap() == "./rules/config" {
configs::CONFIG.write().unwrap().args.config = CURRENT_EXE_PATH.join("rules/config");
}
if let Some(csv_path) = &configs::CONFIG.read().unwrap().args.output {
let pivot_key_unions = PIVOT_KEYWORD.read().unwrap();
pivot_key_unions.iter().for_each(|(key, _)| {