cleanup, docs
This commit is contained in:
@@ -2,13 +2,18 @@
|
||||
void file_unlink(String file_name)
|
||||
|
||||
:params
|
||||
file_name : name of the file
|
||||
file_name : file to delete, resolved against the unit's directory
|
||||
return value : none
|
||||
|
||||
:content
|
||||
Deletes a file. Deleting a path that does not exist is a no-op, so it is safe to call before recreating a file.
|
||||
|
||||
:example
|
||||
file_put_contents("/tmp/doc-unlink.txt", "x");
|
||||
file_unlink("/tmp/doc-unlink.txt");
|
||||
print(file_exists("/tmp/doc-unlink.txt") ? "exists" : "gone", "\n");
|
||||
|
||||
:see
|
||||
>sys
|
||||
|
||||
:content
|
||||
Deletes the file identified by `file_name`.
|
||||
|
||||
:example
|
||||
print("file_unlink example\n");
|
||||
file_exists
|
||||
dir_remove
|
||||
|
||||
Reference in New Issue
Block a user