@ -26,6 +26,7 @@ mod interval;
mod config ;
mod live ;
mod context ;
mod job ;
@ -80,6 +81,7 @@ fn print_stats()
static ref BUILD_IDENT : recolored ::ColoredString = "release" . bright_red ( ) ;
}
#[ allow(unused_imports) ]
use std ::ops ::Deref ;
status ! ( "This is the lolicron daemon version {} by {} ({} build)" , env! ( "CARGO_PKG_VERSION" ) , & AUTHORS [ .. ] , BUILD_IDENT . deref ( ) ) ;
status ! ( "---" ) ;
@ -92,6 +94,12 @@ fn print_stats()
#[ cfg(feature= " threaded " ) ] status ! ( " +threaded" . red ( ) ) ;
#[ cfg(not(feature= " threaded " )) ] status ! ( " -threaded" . bright_blue ( ) ) ;
#[ cfg(feature= " watcher " ) ] status ! ( " +watcher" . red ( ) ) ;
#[ cfg(not(feature= " watcher " )) ] status ! ( " -watcher" . bright_blue ( ) ) ;
#[ cfg(feature= " debug_logger " ) ] status ! ( " +debug_logger" . red ( ) ) ;
#[ cfg(not(feature= " debug_logger " )) ] status ! ( " -debug_logger" . bright_blue ( ) ) ;
#[ cfg(feature= " watcher_unlimited " ) ] status ! ( " +watcher_unlimited" . bright_red ( ) ) ;
#[ cfg(not(feature= " watcher_unlimited " )) ] status ! ( " -watcher_unlimited" . blue ( ) ) ;
@ -111,21 +119,24 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {
log ::init ( log ::Level ::Debug ) ;
debug ! ( "Logger initialised" ) ;
debug ! ( "Logger initialised" ) ; //TODO: Parse config first
print_stats ( ) ;
let oneesan = live ::watch ( "." ) ;
#[ cfg(feature= " watcher " ) ]
{
let mut recv = oneesan . hook ( "src/main.rs" , live ::filter ::ALL ) . await ;
while let Some ( event ) = recv . recv ( ) . await
let oneesan = live ::watch ( "." ) ;
{
important ! ( "Got ev {:?}" , event ) ;
break ;
let mut recv = oneesan . hook ( "src/main.rs" , live ::filter ::ALL ) . await ;
while let Some ( event ) = recv . recv ( ) . await
{
important ! ( "Got ev {:?}" , event ) ;
break ;
}
}
}
oneesan . shutdown ( ) . await . expect ( "oneesan panic" ) ;
oneesan . shutdown ( ) . await . expect ( "oneesan panic" ) ;
}
println! ( "{:?}" , config ::parse_global_single ( "example.rori" ) . await . expect ( "Waaaaaah" ) ) ;