Skip to main content

liboxen/model/
remote.rs

1use serde::{Deserialize, Serialize};
2use utoipa::ToSchema;
3#[derive(Serialize, Deserialize, Debug, Clone, ToSchema)]
4pub struct Remote {
5    pub name: String,
6    pub url: String,
7}
8
9impl std::fmt::Display for Remote {
10    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
11        write!(f, "[{}] '{}'", self.name, self.url)
12    }
13}
14
15impl std::error::Error for Remote {}