diff --git a/sdgb-cli/src/commands.rs b/sdgb-cli/src/commands.rs index a761d64..98dda09 100644 --- a/sdgb-cli/src/commands.rs +++ b/sdgb-cli/src/commands.rs @@ -49,8 +49,9 @@ pub enum Commands { /// JSON format. /// - /// - `origin`: official json response - /// - `dx_rating_net`: DxRatingNet Format + /// `origin`: official json response + /// + /// `dx_rating_net`: DxRatingNet Format #[arg(short, long, default_value_t = RatingFormat::default())] format: RatingFormat, }, @@ -61,8 +62,9 @@ pub enum Commands { /// JSON format. /// - /// - `origin`: official json response - /// - `dx_rating_net`: DxRatingNet Format + /// `origin`: official json response + /// + /// `dx_rating_net`: DxRatingNet Format #[arg(short, long, default_value_t = RatingFormat::default())] format: RatingFormat, }, diff --git a/sdgb-cli/src/main.rs b/sdgb-cli/src/main.rs index 2a03a97..9ab17e9 100644 --- a/sdgb-cli/src/main.rs +++ b/sdgb-cli/src/main.rs @@ -113,10 +113,12 @@ async fn main() -> Result<(), Box> { match (human_readable, format) { (true, _) => { - for detail in music_detail { + for detail in &music_detail { println!("{detail}"); println!("----------"); } + + println!("共查询到 {} 条记录!", music_detail.len()); } (false, RatingFormat::Origin) => json_display(music_detail)?, (false, RatingFormat::DxRatingNet) => {