mirror of
https://gitlab.com/Anson-Projects/zine.git
synced 2025-07-27 08:41:25 +00:00
Make featured post temporary
Also remove factorio since it posts so frequently
This commit is contained in:
@@ -17,17 +17,14 @@ fn main() -> Result<(), Box<dyn Error>> {
|
||||
simple_logger::init_with_level(log::Level::Info).unwrap();
|
||||
|
||||
let featured = read_feed("featured_feeds.txt").first().unwrap().clone();
|
||||
let mut entries = read_feed("feeds.txt");
|
||||
let entries = read_feed("feeds.txt");
|
||||
|
||||
// Move featured article to the front
|
||||
entries.retain(|entry| entry != &featured);
|
||||
entries.insert(0, featured);
|
||||
log::info!(
|
||||
"Featured article: {}",
|
||||
entries[0].links.first().unwrap().href.as_str()
|
||||
);
|
||||
|
||||
let index = index_generator::generate_index(entries);
|
||||
let index = index_generator::generate_index(entries, featured);
|
||||
|
||||
let output_path = Path::new("output/index.html");
|
||||
DirBuilder::new()
|
||||
|
Reference in New Issue
Block a user