llm
Download
38 lines 879 BGroffModified 2026-09-01 raw
1234567891011121314151617181920212223242526272829303132333435363738
'\" t
.\" Copyright (c) 2026 Bruce Hill
.\" All rights reserved.
.\"
.TH Path.exists 3 2026-09-01 "Tomo man-pages"
.SH NAME
Path.exists \- check if a path exists
.SH LIBRARY
Tomo Standard Library
.SH SYNOPSIS
.nf
.BI Path.exists\ :\ func(path:\ Path\ ->\ Bool)
.fi
.SH DESCRIPTION
Checks if a file or directory exists at the specified path.


.SH ARGUMENTS

.TS
allbox;
lb lb lbx
l l l.
Name	Type	Description
path	Path	The path to check. 
.TE
.SH RETURN
`yes` if the file or directory exists, otherwise `no`.

.SH NOTES
This answers about the moment it is asked. Deciding what to do from it races with anything else touching the filesystem; prefer operations that say what they did, such as `Path.create_directory` (which succeeds if the directory is already there) or `Path.remove` with `ignore_missing`.

.SH EXAMPLES
.EX
assert (/).exists()
.EE
.SH SEE ALSO
.BR Tomo-Path (3)