cleanup, docs

This commit is contained in:
root
2026-06-16 23:02:45 +00:00
parent ea08d5f28b
commit b8b56cf3dd
160 changed files with 1076 additions and 511 deletions
+12 -7
View File
@@ -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