cli: Don't fail on `rad ls` if project is invalid

This commit is contained in:
cloudhead 2024-08-07 10:40:46 +02:00
parent 16560950ec
commit 73f3c49689
No known key found for this signature in database
1 changed files with 7 additions and 1 deletions

View File

@ -122,7 +122,13 @@ pub fn run(options: Options, ctx: impl term::Context) -> anyhow::Result<()> {
if !seeded && options.seeded { if !seeded && options.seeded {
continue; continue;
} }
let proj = doc.project()?; let proj = match doc.project() {
Ok(p) => p,
Err(e) => {
log::error!(target: "cli", "Error loading project payload for {rid}: {e}");
continue;
}
};
let head = term::format::oid(head).into(); let head = term::format::oid(head).into();
rows.push([ rows.push([