aboutsummaryrefslogtreecommitdiff
path: root/src/post
diff options
context:
space:
mode:
authorXe Iaso <me@christine.website>2022-03-18 21:29:54 +0000
committerXe Iaso <me@christine.website>2022-03-18 21:29:54 +0000
commit6682de204390eeaadf3d1e75c1b7dab1e654d8b3 (patch)
tree5b438a2170dcbd456b06d8b790bbdf188cc78c62 /src/post
parentf45ca40ae1052d46611ff2f27ad281695afc4f8f (diff)
downloadxesite-6682de204390eeaadf3d1e75c1b7dab1e654d8b3.tar.xz
xesite-6682de204390eeaadf3d1e75c1b7dab1e654d8b3.zip
broken state
Signed-off-by: Xe Iaso <me@christine.website>
Diffstat (limited to 'src/post')
-rw-r--r--src/post/mod.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/post/mod.rs b/src/post/mod.rs
index 750d022..1cd7f92 100644
--- a/src/post/mod.rs
+++ b/src/post/mod.rs
@@ -1,13 +1,13 @@
use chrono::prelude::*;
use color_eyre::eyre::{eyre, Result, WrapErr};
use glob::glob;
-use serde::Serialize;
+use serde::{Deserialize, Serialize};
use std::{borrow::Borrow, cmp::Ordering, path::PathBuf};
use tokio::fs;
pub mod frontmatter;
-#[derive(Eq, PartialEq, Debug, Clone)]
+#[derive(Eq, PartialEq, Debug, Clone, Serialize, Deserialize)]
pub struct Post {
pub front_matter: frontmatter::Data,
pub link: String,
@@ -19,7 +19,7 @@ pub struct Post {
}
/// Used with the Android app to show information in a widget.
-#[derive(Eq, PartialEq, Debug, Clone, Serialize)]
+#[derive(Eq, PartialEq, Debug, Clone, Serialize, Deserialize)]
pub struct NewPost {
pub title: String,
pub summary: String,