Warning: main(/www/www/htdocs/style/globals.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/utilities/r/rmdir.html on line 1

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/globals.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/utilities/r/rmdir.html on line 1

Warning: main(/www/www/htdocs/style/header.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/utilities/r/rmdir.html on line 8

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/header.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/utilities/r/rmdir.html on line 8

rmdir

Remove directories (POSIX)

Syntax:

rmdir [-p] dir...

Runs on:

QNX Neutrino, Microsoft Windows

Options:

-p
Remove the entire directory path (consisting only of directories that are empty except for the named pathname components) of the directories specified on the command line. (See example.)
dir
The pathname of an empty directory to be removed.

Description:

The rmdir utility removes the directory specified by each dir operand, provided the directory is empty.

The rmdir utility processes directories in the order they're specified on the command line. If you specify a parent directory, you should specify its subdirectory before the parent directory. That way, the parent directory will be empty when the rmdir utility tries to remove it.

Examples:

Remove the subdirectory oldfiles from the /home/fred directory:

rmdir /home/fred/oldfiles

Remove the directory path dir1/dir2/dir3:

rmdir -p dir1/dir2/dir3

For this command, rmdir first removes dir1/dir2/dir3. If this is successful, it then removes dir1/dir2. If this is also successful, it removes dir1.

Exit status:

0
Each directory specified by a dir operand referred to an empty directory and was removed successfully.
>0
An error occurred.

See also:

rm, find


Warning: main(/www/www/htdocs/style/footer.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/utilities/r/rmdir.html on line 127

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/footer.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/utilities/r/rmdir.html on line 127