mirror of
https://github.com/rojo-rbx/rojo.git
synced 2026-10-22 13:21:38 +00:00
Fix #21: High CPU usage in a small project
This commit is contained in:
parent
b4e31ea35d
commit
ae6ca6fb23
2 changed files with 7 additions and 2 deletions
|
|
@ -22,6 +22,7 @@ pub mod vfs_watch;
|
||||||
use std::path::{Path, PathBuf};
|
use std::path::{Path, PathBuf};
|
||||||
use std::sync::{Arc, Mutex};
|
use std::sync::{Arc, Mutex};
|
||||||
use std::thread;
|
use std::thread;
|
||||||
|
use std::time::Duration;
|
||||||
|
|
||||||
use core::Config;
|
use core::Config;
|
||||||
use pathext::canonicalish;
|
use pathext::canonicalish;
|
||||||
|
|
@ -193,7 +194,9 @@ fn main() {
|
||||||
|
|
||||||
println!("Server listening on port {}", port);
|
println!("Server listening on port {}", port);
|
||||||
|
|
||||||
loop {}
|
loop {
|
||||||
|
thread::sleep(Duration::from_secs(1));
|
||||||
|
}
|
||||||
},
|
},
|
||||||
("pack", _) => {
|
("pack", _) => {
|
||||||
eprintln!("'rojo pack' is not yet implemented!");
|
eprintln!("'rojo pack' is not yet implemented!");
|
||||||
|
|
|
||||||
|
|
@ -92,6 +92,8 @@ impl VfsWatcher {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
loop {}
|
loop {
|
||||||
|
thread::sleep(Duration::from_secs(1));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue