summaryrefslogtreecommitdiff
path: root/shell/bin/mkdir.php
blob: 565f47ad3b57e3d1d282bd492d444221378bdce5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
<?php
class p_mkdir extends prog {
	public static function main($args, $env) {
		$me = array_shift($args);
		@$recursive = ($args[0]=='-p');
		if ($recursive) {
			array_shift($args);
		}
		foreach ($args as $dir) {
			mkdir($dir, umask(), $recursive);
		}
	}
}