feat: add function to parse editor output in edit

This commit is contained in:
2026-09-03 15:18:53 +02:00
parent f8a51ccd48
commit 0b586ecef0
2 changed files with 20 additions and 14 deletions
+2 -2
View File
@@ -72,9 +72,8 @@ fn main() -> Result<(), Box<dyn std::error::Error>> {
}
}
Commands::Edit { file } => {
let path = PathBuf::from("/tmp/keks-sort-metadata");
let tag = get_metadata(file);
edit(path, tag)?;
edit(file.to_path_buf(), tag)?;
}
}
@@ -91,5 +90,6 @@ fn get_metadata<P: AsRef<OsStr>>(file_path: P) -> lofty::tag::Tag {
Some(primary_tag) => primary_tag,
None => tagged_file.first_tag().expect("ERROR: No tags found!"),
};
tag.clone()
}