Beets config is ignored over SSH (#49)

Closes #42

Reviewed-on: https://git.wojciechkozlowski.eu/wojtek/musichoard/pulls/49
This commit is contained in:
Wojciech Kozlowski 2023-04-27 19:34:07 +02:00
parent 2ecc64437a
commit ad18c7e384

View File

@ -62,7 +62,14 @@ fn main() {
if let Some(uri) = opt.beets_ssh_uri {
let uri = uri.into_string().expect("invalid SSH URI");
let lib_exec = BeetsLibrarySshExecutor::new(uri).expect("failed to initialise beets");
let beets_config_file_path = opt
.beets_config_file_path
.map(|s| s.into_string())
.transpose()
.expect("failed to extract beets config file path");
let lib_exec = BeetsLibrarySshExecutor::new(uri)
.expect("failed to initialise beets")
.config(beets_config_file_path);
let db_exec = JsonDatabaseFileBackend::new(&opt.database_file_path);
with(BeetsLibrary::new(lib_exec), JsonDatabase::new(db_exec));
} else {