use chrono::{DateTime, Utc}; use serde::{Deserialize, Serialize}; use std::fmt::Display; #[derive(Debug)] pub enum GuardianPullRequests { AuthoredByMe, ReviewedByMe, } impl Display for GuardianPullRequests { fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { match &self { GuardianPullRequests::AuthoredByMe => write!(f, "pull requests authored by you"), GuardianPullRequests::ReviewedByMe => write!(f, "pull requests reviewed by you"), } } } #[derive(Debug, Serialize, Deserialize)] pub struct GithubSearchResponse { pub total_count: u32, pub incomplete_results: bool, pub items: Vec, } #[derive(Debug, Serialize, Deserialize)] pub struct GithubSearchResponseItem { pub url: String, pub repository_url: String, pub labels_url: String, pub comments_url: String, pub events_url: String, pub html_url: String, pub id: u64, pub node_id: String, pub number: u32, pub title: String, pub user: User, pub labels: Vec