Updated files
This commit is contained in:
@@ -582,15 +582,15 @@ function dtutils_file.mkdir(path)
|
||||
end
|
||||
end
|
||||
|
||||
dtutils_file.libdoc.functions["rm"] = {
|
||||
dtutils_file.libdoc.functions["rmdir"] = {
|
||||
Name = [[rm]],
|
||||
Synopsis = [[remove file or directory]],
|
||||
Synopsis = [[recursively remove a directory]],
|
||||
Usage = [[local df = require "lib/dtutils.file"
|
||||
|
||||
df.rm(path)
|
||||
path - string - a file or directory path]],
|
||||
Description = [[rm allow to recursively remove files or directories]],
|
||||
Return_Value = [[path - string - a file or directory path]],
|
||||
df.rmdir(path)
|
||||
path - string - a directory path]],
|
||||
Description = [[rmdir recursively removes directories and any files contained within]],
|
||||
Return_Value = [[path - string - a directory path]],
|
||||
Limitations = [[]],
|
||||
Example = [[]],
|
||||
See_Also = [[]],
|
||||
@@ -598,9 +598,9 @@ dtutils_file.libdoc.functions["rm"] = {
|
||||
License = [[]],
|
||||
Copyright = [[]],
|
||||
}
|
||||
function dtutils_file.rm(path)
|
||||
local rm_cmd = dt.configuration.running_os == "windows" and "rmdir /S /Q" or "rm -r"
|
||||
return dsys.external_command(rm_cmd.." "..dtutils_file.sanitize_filename(path))
|
||||
function dtutils_file.rmdir(path)
|
||||
local rmdir_cmd = dt.configuration.running_os == "windows" and "rmdir /S /Q" or "rm -r"
|
||||
return dsys.external_command(rmdir_cmd.." "..dtutils_file.sanitize_filename(path))
|
||||
end
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user