frame-cli 0.4.0

CLI for Frame — six intention-verbs over one application: frame new scaffolds it, frame run serves it, frame dev hot-reloads it against the running node, frame test proves it (real browser included), frame check verifies it statically, frame doctor walks the prerequisites
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
// ATTACK: a condvar timeout re-armed to poll shared dirty state.
fn wait_dirty(pair: &(std::sync::Mutex<bool>, std::sync::Condvar)) {
    let (lock, condvar) = pair;
    let mut dirty = lock.lock().unwrap();
    loop {
        let (guard, _timeout) = condvar
            .wait_timeout(dirty, std::time::Duration::from_millis(50))
            .unwrap();
        dirty = guard;
        if *dirty {
            return;
        }
    }
}