mkdir: Manipulaton of Directories and File Permissions

Description Usage Arguments Value Author(s)

Description

This is a wrapper around base::dir.create, which creates directories.

Usage

1
mkdir(path, showWarnings = TRUE, recursive = FALSE, mode = "0777")

Arguments

path

a character vector containing a single path name. Tilde expansion (see path.expand) is done.

showWarnings

logical; should the warnings on failure be shown?

recursive

logical. Should elements of the path other than the last be created? If true, like the Unix command mkdir -p.

mode

the mode to be used on Unix-alikes: it will be coerced by as.octmode. For Sys.chmod it is recycled along paths.

Value

mkdir returns invisibly a logical vector indicating if the operation succeeded for each of the files attempted. Using a missing value for a path name will always be regarded as a failure. dir.create indicates failure if the directory already exists. If showWarnings = TRUE, dir.create will give a warning for an unexpected failure (e.g. not for a missing value nor for an already existing component for recursive = TRUE).

Author(s)

Ross Ihaka, Brian Ripley


drmjc/mjcbase documentation built on May 15, 2019, 2:27 p.m.