This commit is contained in:
parent
f34fd82b3f
commit
69c1b64433
10
src/main.rs
10
src/main.rs
@ -119,18 +119,18 @@ fn main() {
|
||||
fs::write(&format!("output/{law_name}.html"), &site).expect("Unable to write file");
|
||||
}
|
||||
let style = fs::read_to_string("templates/style.css").unwrap();
|
||||
fs::write(&format!("output/style.css"), &style).expect("Unable to write file");
|
||||
fs::write("output/style.css", style).expect("Unable to write file");
|
||||
|
||||
let style = fs::read_to_string("templates/pico.min.css").unwrap();
|
||||
fs::write(&format!("output/pico.min.css"), &style).expect("Unable to write file");
|
||||
fs::write("output/pico.min.css", style).expect("Unable to write file");
|
||||
|
||||
let js = fs::read_to_string("templates/app.js").unwrap();
|
||||
fs::write(&format!("output/app.js"), &js).expect("Unable to write file");
|
||||
fs::write("output/app.js", js).expect("Unable to write file");
|
||||
|
||||
let js = fs::read_to_string("templates/toggle.js").unwrap();
|
||||
fs::write(&format!("output/toggle.js"), &js).expect("Unable to write file");
|
||||
fs::write("output/toggle.js", js).expect("Unable to write file");
|
||||
|
||||
let mut index = fs::read_to_string("templates/index.html").unwrap();
|
||||
index = index.replace("{{content}}", &li_of_files);
|
||||
fs::write(&format!("output/index.html"), &index).expect("Unable to write file");
|
||||
fs::write("output/index.html", &index).expect("Unable to write file");
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user