cargo::util::flock

Function try_acquire

Source
fn try_acquire(
    path: &Path,
    lock_try: &dyn Fn() -> Result<()>,
) -> CargoResult<bool>