Examples for 'fs::fs_perms'


Create, modify and view file permissions

Aliases: fs_perms as_fs_perms

Keywords:

### ** Examples

# Integer and numeric
fs_perms(420L)
[1] rw-r--r--
fs_perms(c(511, 420))
[1] rwxrwxrwx rw-r--r--
# Octal
fs_perms("777")
[1] rwxrwxrwx
fs_perms(c("777", "644"))
[1] rwxrwxrwx rw-r--r--
# Symbolic
fs_perms("a+rwx")
[1] rwxrwxrwx
fs_perms(c("a+rwx", "u+rw,go+r"))
[1] rwxrwxrwx rw-r--r--
# Use the `&` and `|`operators to check for certain permissions
(fs_perms("777") & "u+r") == "u+r"
[1] TRUE

[Package fs version 1.6.5 Index]