add-file-permissions ( path n -- ) (original) (raw)

add-file-permissions ( path n -- )
Unix file attributes » Unix file permissions

Prev: other-execute? ( obj -- ? )
Next: remove-file-permissions ( path n -- )

Vocabulary
io.files.info.unix

Inputs

path a pathname string
n an integer

Outputs
None

Word description
Ensures that the bits from n are set in the Unix file permissions for a given file.

Definition

USING: kernel math ;

IN: io.files.info.unix

: add-file-permissions ( path n -- )
over file-permissions bitor set-file-permissions ;