Update storage.php
This commit is contained in:
parent
18f8bee467
commit
6898571131
|
|
@ -20,11 +20,21 @@ if(!function_exists("get_current_working_dir")) {
|
||||||
case "basename":
|
case "basename":
|
||||||
$working_dir = basename(__DIR__);
|
$working_dir = basename(__DIR__);
|
||||||
break;
|
break;
|
||||||
case "pwd":
|
case "unix":
|
||||||
if(loadHelper("exectool")) {
|
if(loadHelper("exectool")) {
|
||||||
$working_dir = exec_command("pwd");
|
$working_dir = exec_command("pwd");
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
case "windows":
|
||||||
|
if(loadHelper("exectool")) {
|
||||||
|
$exec_contents = implode("\r\n", array("@echo off", "SET var=%cd%", "ECHO %var%"));
|
||||||
|
$exec_file = write_storage_file($file_contents, array(
|
||||||
|
"filename" => "pwd.bat"
|
||||||
|
));
|
||||||
|
$working_dir = exec_command($exec_file);
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return $working_dir;
|
return $working_dir;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user