Update cargo dev serve command to look over the correct files

This commit is contained in:
Guillaume Gomez 2024-08-13 20:47:42 +02:00
parent b522e7a944
commit 9661ba0740

View File

@ -19,7 +19,9 @@ pub fn run(port: u16, lint: Option<String>) -> ! {
});
loop {
if mtime("util/gh-pages/index.html") < mtime("clippy_lints/src") {
let index_time = mtime("util/gh-pages/index.html");
if index_time < mtime("clippy_lints/src") || index_time < mtime("util/gh-pages/index_template.html") {
Command::new(env::var("CARGO").unwrap_or("cargo".into()))
.arg("collect-metadata")
.spawn()