Copy And Overwrite (LCC.web_file.copy_overwrite)
Signature
ok, err = LCC.web_file.copy_overwrite(src, target, timeout?)
Parameters
- src
String. Source path. - target
String. Destination path. - timeout
Number, optional. Request timeout in seconds, default60.
Returns
- ok
Boolean.trueon success,nilon failure. - err
String ornil. Error description when the copy fails.
Notes
Convenience wrapper around
web_file.copywithmode = "overwrite".
Existing targets are deleted before copying.
Example
local ok, err = LCC.web_file.copy_overwrite("/scripts", "/deploy/scripts")
if not ok then
error(err)
end