Compare commits
No commits in common. "2d8d0db4cb421e8578354d739db5ae060599bcea" and "930115813cae5d45a34cb9eb56c62472d0ce086a" have entirely different histories.
2d8d0db4cb
...
930115813c
1 changed files with 28 additions and 33 deletions
|
|
@ -291,20 +291,10 @@ fn handle_command(
|
|||
|
||||
Commands::Show { issue_id } => {
|
||||
let issues = entomologist::database::read_issues_database(issues_database_source)?;
|
||||
let Some(issue) = issues.get_issue(issue_id) else {
|
||||
return Err(anyhow::anyhow!("issue {} not found", issue_id));
|
||||
};
|
||||
match issues.get_issue(issue_id) {
|
||||
Some(issue) => {
|
||||
println!("issue {}", issue_id);
|
||||
println!("author: {}", issue.author);
|
||||
if issue.tags.len() > 0 {
|
||||
print!("tags: ");
|
||||
let mut separator = "";
|
||||
for tag in &issue.tags {
|
||||
print!("{}{}", separator, tag);
|
||||
separator = ", ";
|
||||
}
|
||||
println!("");
|
||||
}
|
||||
println!("creation_time: {}", issue.creation_time);
|
||||
if let Some(done_time) = &issue.done_time {
|
||||
println!("done_time: {}", done_time);
|
||||
|
|
@ -327,6 +317,11 @@ fn handle_command(
|
|||
println!("{}", comment.description);
|
||||
}
|
||||
}
|
||||
None => {
|
||||
return Err(anyhow::anyhow!("issue {} not found", issue_id));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Commands::State {
|
||||
issue_id,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue