20.5 Creating directories

Function: mbfl_file_enable_make_directory

Declare the commands required to create directories. Declaring the intention to use a program

The programs are: mkdir.

Function: mbfl_file_make_directory PATHNAME
Function: mbfl_file_make_directory PATHNAME PERMISSIONS

Create a directory named PATHNAME; all the non–existent parents are created, too. If PERMISSIONS is present: it is the specification of directory permissions in octal mode.

This function does not test if the directory already exists: the command is always executed.

Function: mbfl_file_make_if_not_directory PATHNAME
Function: mbfl_file_make_if_not_directory PATHNAME PERMISSIONS

Wrapper for mbfl_file_make_directory() that creates the directory if it does not exist.

If a sudo user was requested: this function resets the request even if no command has been executed.

Function: mbfl_exec_mkdir ARG

Execute the program mkdir using the given optional command line arguments.


This document describes version 3.0.0-devel.9 of Marcos Bash Functions Library.