Zig 0.17.0-dev (Split by item)

This is an example of documentation generated by ZigDoc, an alternative to Zig's built-in Auto Doc feature. See also examples in other modes/formats. The project being documented here (as the example) is the Zig library itself.

setPermissions

Also known as "chmod".

The process must have the correct privileges in order to do this successfully, or must have the effective user ID matching the owner of the file.

File.setPermissions
pub fn setPermissions(file: File, io: Io, new_permissions: Permissions) SetPermissionsError!void

File

lib/std/Io/File.zig:305

Code

pub fn setPermissions(file: File, io: Io, new_permissions: Permissions) SetPermissionsError!void {
    return io.vtable.fileSetPermissions(io.userdata, file, new_permissions);
}