diff options
| author | Ruben Beltran del Rio <git@r.bdr.sh> | 2025-03-06 22:17:49 +0100 |
|---|---|---|
| committer | Ruben Beltran del Rio <git@r.bdr.sh> | 2025-03-06 22:17:49 +0100 |
| commit | 7761f8b4814b86bb23fb3d1b8498b147bd1313e9 (patch) | |
| tree | 3c368df93d2acaee748a59e5cfacb03ae6ee637a /src | |
| parent | a9e0a8829a0b83cc44e1b24a8ae5df762adf0f76 (diff) | |
Formatting
Diffstat (limited to 'src')
| -rw-r--r-- | src/archiver/gemini.rs | 2 | ||||
| -rw-r--r-- | src/archiver/gopher.rs | 2 | ||||
| -rw-r--r-- | src/archiver/mod.rs | 2 | ||||
| -rw-r--r-- | src/command/generate.rs | 2 | ||||
| -rw-r--r-- | src/generator/html.rs | 2 | ||||
| -rw-r--r-- | src/generator/rss.rs | 2 | ||||
| -rw-r--r-- | src/generator/txt.rs | 2 | ||||
| -rw-r--r-- | src/main.rs | 2 | ||||
| -rw-r--r-- | src/metadata.rs | 2 | ||||
| -rw-r--r-- | src/remote/mod.rs | 2 | ||||
| -rw-r--r-- | src/template.rs | 2 |
11 files changed, 11 insertions, 11 deletions
diff --git a/src/archiver/gemini.rs b/src/archiver/gemini.rs index 0cde0b1..f4df9f8 100644 --- a/src/archiver/gemini.rs +++ b/src/archiver/gemini.rs @@ -1,4 +1,4 @@ -use crate::template::{find, parse, Context}; +use crate::template::{Context, find, parse}; use std::fs::write; use std::io::{Error, ErrorKind::Other, Result}; use std::path::Path; diff --git a/src/archiver/gopher.rs b/src/archiver/gopher.rs index 77f23b9..8c37022 100644 --- a/src/archiver/gopher.rs +++ b/src/archiver/gopher.rs @@ -1,4 +1,4 @@ -use crate::template::{find, parse, Context}; +use crate::template::{Context, find, parse}; use std::fs::write; use std::io::{Error, ErrorKind::Other, Result}; use std::path::Path; diff --git a/src/archiver/mod.rs b/src/archiver/mod.rs index ddca473..25c45a8 100644 --- a/src/archiver/mod.rs +++ b/src/archiver/mod.rs @@ -7,7 +7,7 @@ use std::collections::HashMap; use std::fs::read_dir; use std::io::Result; use std::path::{Path, PathBuf}; -use time::{format_description::FormatItem, macros::format_description, OffsetDateTime}; +use time::{OffsetDateTime, format_description::FormatItem, macros::format_description}; const DATE_FORMAT: &[FormatItem<'_>] = format_description!("[year]-[month]-[day]"); diff --git a/src/command/generate.rs b/src/command/generate.rs index e96ff33..45d5850 100644 --- a/src/command/generate.rs +++ b/src/command/generate.rs @@ -5,7 +5,7 @@ use crate::generator::generate; use crate::metadata::Metadata; use crate::post::Post; use gema_texto::{gemini_parser::parse, html_renderer::render_html}; -use std::fs::{create_dir_all, read_dir, remove_dir_all, File}; +use std::fs::{File, create_dir_all, read_dir, remove_dir_all}; use std::io::{Read, Result}; use std::path::Path; diff --git a/src/generator/html.rs b/src/generator/html.rs index 7af4c73..ade3eee 100644 --- a/src/generator/html.rs +++ b/src/generator/html.rs @@ -1,4 +1,4 @@ -use crate::template::{find, parse, Context}; +use crate::template::{Context, find, parse}; use std::fs::write; use std::io::{Error, ErrorKind::Other, Result}; use std::path::Path; diff --git a/src/generator/rss.rs b/src/generator/rss.rs index 0e28777..a36ad14 100644 --- a/src/generator/rss.rs +++ b/src/generator/rss.rs @@ -1,4 +1,4 @@ -use crate::template::{find, parse, Context}; +use crate::template::{Context, find, parse}; use std::fs::write; use std::io::{Error, ErrorKind::Other, Result}; use std::path::Path; diff --git a/src/generator/txt.rs b/src/generator/txt.rs index d35720d..cc590a4 100644 --- a/src/generator/txt.rs +++ b/src/generator/txt.rs @@ -1,4 +1,4 @@ -use crate::template::{find, parse, Context}; +use crate::template::{Context, find, parse}; use std::fs::write; use std::io::{Error, ErrorKind::Other, Result}; use std::path::Path; diff --git a/src/main.rs b/src/main.rs index ae36289..45ebe7b 100644 --- a/src/main.rs +++ b/src/main.rs @@ -9,7 +9,7 @@ mod remote; mod template; mod utils; -use command::{available_commands, help::Help, Command}; +use command::{Command, available_commands, help::Help}; use configuration::Configuration; use std::env::args; use std::io::Result; diff --git a/src/metadata.rs b/src/metadata.rs index 140d1f4..8eff5cb 100644 --- a/src/metadata.rs +++ b/src/metadata.rs @@ -3,7 +3,7 @@ use std::fs::File; use std::io::Read; use std::path::PathBuf; use std::time::{SystemTime, UNIX_EPOCH}; -use time::{format_description::well_known::Rfc2822, OffsetDateTime}; +use time::{OffsetDateTime, format_description::well_known::Rfc2822}; #[derive(Serialize, Deserialize)] pub struct Metadata { diff --git a/src/remote/mod.rs b/src/remote/mod.rs index 8431c75..90f400c 100644 --- a/src/remote/mod.rs +++ b/src/remote/mod.rs @@ -1,6 +1,6 @@ mod git; -use std::fs::{create_dir_all, remove_file, write, File}; +use std::fs::{File, create_dir_all, remove_file, write}; use std::io::{Error, ErrorKind::Other, Read, Result}; use std::path::Path; diff --git a/src/template.rs b/src/template.rs index aef3440..7e47e65 100644 --- a/src/template.rs +++ b/src/template.rs @@ -262,7 +262,7 @@ fn tokenize(template: &str, tokens: &mut Vec<Token>) -> Result<()> { return Err(Error::new( Other, "{{ }} is not a valid directive. Need one of: =, ? or ~.", - )) + )); } } } |