feat(server): implement Display for forge::Commit
This commit is contained in:
parent
546d91554c
commit
d64024e1ab
1 changed files with 7 additions and 0 deletions
|
@ -1,3 +1,5 @@
|
||||||
|
use std::fmt::{Display, Formatter};
|
||||||
|
|
||||||
pub mod forgejo;
|
pub mod forgejo;
|
||||||
|
|
||||||
#[derive(Clone, Debug)]
|
#[derive(Clone, Debug)]
|
||||||
|
@ -11,3 +13,8 @@ pub struct CommitHistories {
|
||||||
pub struct Commit {
|
pub struct Commit {
|
||||||
pub sha: String,
|
pub sha: String,
|
||||||
}
|
}
|
||||||
|
impl Display for Commit {
|
||||||
|
fn fmt(&self, f: &mut Formatter) -> std::fmt::Result {
|
||||||
|
write!(f, "{}", self.sha)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in a new issue