From 683358f3c1e4bfaa11bade2c9f756f67fc9c97bc Mon Sep 17 00:00:00 2001 From: baalajimaestro Date: Sun, 24 Sep 2023 22:03:32 +0530 Subject: [PATCH] Switch it to gitea Signed-off-by: baalajimaestro --- src/main.rs | 32 +++++++++++++++++--------------- 1 file changed, 17 insertions(+), 15 deletions(-) diff --git a/src/main.rs b/src/main.rs index 09df644..fcd8883 100644 --- a/src/main.rs +++ b/src/main.rs @@ -24,43 +24,45 @@ struct Paste { #[derive(Serialize, Deserialize)] struct GitLabSuccessJSON { - file_name: String, - file_path: String, + name: String, + path: String, size: u64, encoding: String, - content_sha256: String, - r#ref: String, - blob_id: String, - commit_id: String, - last_commit_id: String, - execute_filemode: bool, - content: String, + sha: String, + target: Option, + url: String, + html_url: String, + git_url: String, + submodule_git_url: Option, + content: String } #[derive(Serialize, Deserialize)] struct GitLabFailedJSON { + errors: Option, message: String, + url: String } #[get("/")] async fn paste_render(data: Data