crabmail

Static HTML email archive viewer in Rust
git clone git://git.alexwennerberg.com/crabmail
Log | Files | Refs | README | LICENSE

commit b52f6dc072148a2c8b8a6d29535d68c2a5fd693b
parent ee528ebb980f3632de17bbee7728f443b0726035
Author: alex wennerberg <alex@alexwennerberg.com>
Date:   Fri, 31 Dec 2021 16:06:40 -0800

add subfolder check

Diffstat:
Msrc/main.rs | 4++++
1 file changed, 4 insertions(+), 0 deletions(-)

diff --git a/src/main.rs b/src/main.rs @@ -496,6 +496,10 @@ fn main() -> Result<()> { INSTANCE.set(config).unwrap(); let out_dir = &Config::global().out_dir; + let is_subfolder = std::fs::read_dir(&args.maildir) + .unwrap() + .any(|a| a.unwrap().file_name().to_str().unwrap() == "cur"); + let maildir = Maildir::from(args.maildir.as_str()); // new world WIP // let mut threader = threading::Arena::default();