(path: &Path)
| 127 | } |
| 128 | |
| 129 | fn file_mode(path: &Path) -> Result<u32> { |
| 130 | #[cfg(unix)] |
| 131 | { |
| 132 | use std::os::unix::fs::PermissionsExt; |
| 133 | Ok(fs::metadata(path)?.permissions().mode() & 0o7777) |
| 134 | } |
| 135 | #[cfg(not(unix))] |
| 136 | { |
| 137 | Ok(u32::from(fs::metadata(path)?.permissions().readonly())) |
| 138 | } |
| 139 | } |
| 140 | |
| 141 | fn record(repo: &Repository, message: &str, tick: &mut i64) -> Result<()> { |
| 142 | let mut header = ChangeHeader::new(message); |
no test coverage detected