
Next: Directories
Up: Filesystem Utilities
Previous: Pathnames
The file management utilities are:
- (file-exists? path)
returns #t if a file (not a directory) with the path
path exists, #f otherwise.
- (delete-file path)
deletes the file with pathname path if it exists.
Returns #t if a file was deleted successfully, #f
otherwise.
- (rename-file old new)
renames the file with pathname old if it exists to
the pathname new. Returns #t if a file was renamed
successfully, #f otherwise.
- (file-modify-seconds path)
returns the file's last modification date as platform-specific seconds
(see also current-seconds and seconds->date in
section 3.20).
-
(file-or-directory-permissions path) returns a list containing
'read, 'write, and/or 'execute
for the given file or directory path. If no such file or directory
exists, the empty list is returned.
PLT