Check if this file is executable. A file is considered executable if any of the execute bits (owner, group, or other) are set. # Returns `true` if any execute bit is set.
(&self)
| 397 | /// |
| 398 | /// `true` if any execute bit is set. |
| 399 | pub fn is_executable(&self) -> bool { |
| 400 | // Execute bits are at positions 0, 3, 6 (other, group, owner) |
| 401 | (self.permissions & 0o111) != 0 |
| 402 | } |
| 403 | |
| 404 | /// Create metadata that's the same but with executable permission. |
| 405 | /// |