pub fn lock<P: AsRef<Path>>(file_path: &LockPath<P>) -> Result<LockGuard>
Locks the file in a blocking manner.
Propagates any std::io::Errors caused by opening / locking the file.
std::io::Error