This is the file-finder Reference Manual, version 0.2.0, generated automatically by Declt version 4.0 beta 2 "William Riker" on Sun Dec 15 06:06:25 2024 GMT+0.
The main system appears first, followed by any subsystem dependency.
file-finder
File finder. Enable rapid file search, inspection and manipulation.
vindarel
Pierre Neidhardt <mail@ambrevar.xyz>
GPL3+
0.2.0
named-readtables
(system).
alexandria
(system).
serapeum
(system).
local-time
(system).
file-attributes
(system).
str
(system).
package.lisp
(file).
file.lisp
(file).
predicates.lisp
(file).
Files are sorted by type and then listed depth-first from the systems components trees.
file-finder/file-finder.asd
file-finder/package.lisp
file-finder/file.lisp
file-finder/predicates.lisp
file-finder/file.lisp
file-finder
(system).
*descend-hidden-directories*
(special variable).
*exclude-directories*
(special variable).
*file-constructor*
(special variable).
*include-directories*
(special variable).
*include-hidden-files*
(special variable).
*print-abbreviate-home?*
(special variable).
*print-abbreviation-length*
(special variable).
*print-abbreviation-threshold*
(special variable).
*print-date?*
(special variable).
*print-reader-macro*
(special variable).
*print-relative-path?*
(special variable).
*print-size?*
(special variable).
basename
(method).
creation-date
(reader method).
current-directory
(function).
directory?
(method).
disk-usage
(reader method).
exists?
(method).
extension
(method).
(setf extension)
(method).
file
(function).
file
(class).
file-kind
(type).
file=?
(function).
file?
(method).
finder
(function).
finder*
(function).
initialize-instance
(method).
inode
(reader method).
kind
(reader method).
link-count
(reader method).
list-directory
(function).
parent
(method).
path
(method).
path
(method).
path
(reader method).
(setf path)
(method).
print-object
(method).
relative-path
(method).
relative-path
(method).
separator
(function).
size
(reader method).
with-current-directory
(macro).
%specifier->predicate
(function).
*touch-command*
(special variable).
+ls-time-format+
(special variable).
access-date
(reader method).
(setf access-date)
(method).
depth
(function).
disk-usage*
(method).
ensure-match-path-predicates
(function).
every-match-path
(function).
file-reader
(function).
function-specifier
(type).
match-depth<
(function).
match-path
(function).
match-path-end
(function).
modification-date
(reader method).
(setf modification-date)
(method).
parent?
(function).
print-file
(function).
read-/etc/group
(function).
shorten-home
(function).
shorten-path
(function).
uiop-path
(method).
uiop-path
(method).
uiop-path
(method).
file-finder/predicates.lisp
file-finder
(system).
date<
(function).
date>
(function).
every-name~
(function).
every-path~
(function).
extension=
(function).
hidden?
(function).
iname=
(function).
iname~
(function).
name=
(function).
name~
(function).
path$
(function).
path~
(function).
depth<
(function).
Packages are listed by definition order.
file-finder
File object finder, one package for the two project files (file class, finder predicates).
common-lisp
.
*descend-hidden-directories*
(special variable).
*exclude-directories*
(special variable).
*file-constructor*
(special variable).
*include-directories*
(special variable).
*include-hidden-files*
(special variable).
*print-abbreviate-home?*
(special variable).
*print-abbreviation-length*
(special variable).
*print-abbreviation-threshold*
(special variable).
*print-date?*
(special variable).
*print-reader-macro*
(special variable).
*print-relative-path?*
(special variable).
*print-size?*
(special variable).
basename
(generic function).
creation-date
(generic reader).
current-directory
(function).
date<
(function).
date>
(function).
directory?
(generic function).
disk-usage
(generic reader).
every-name~
(function).
every-path~
(function).
exists?
(generic function).
extension
(generic function).
(setf extension)
(generic function).
extension=
(function).
file
(function).
file
(class).
file-kind
(type).
file=?
(function).
file?
(generic function).
finder
(function).
finder*
(function).
hidden?
(function).
iname=
(function).
iname~
(function).
inode
(generic reader).
kind
(generic reader).
link-count
(generic reader).
list-directory
(function).
name=
(function).
name~
(function).
parent
(generic function).
path
(generic function).
(setf path)
(generic function).
path$
(function).
path~
(function).
relative-path
(generic function).
separator
(function).
size
(generic reader).
with-current-directory
(macro).
%specifier->predicate
(function).
*touch-command*
(special variable).
+ls-time-format+
(special variable).
access-date
(generic reader).
(setf access-date)
(generic function).
depth
(function).
depth<
(function).
disk-usage*
(generic function).
ensure-match-path-predicates
(function).
every-match-path
(function).
file-reader
(function).
function-specifier
(type).
match-depth<
(function).
match-path
(function).
match-path-end
(function).
modification-date
(generic reader).
(setf modification-date)
(generic function).
parent?
(function).
print-file
(function).
read-/etc/group
(function).
shorten-home
(function).
shorten-path
(function).
uiop-path
(generic function).
Definitions are sorted by export status, category, package, and then by lexicographic order.
Exclude these directories. Typically: node_modules.
Use pathnames with #p instead of simple strings.
Function that takes a path and returns a ‘file’-like object.
When non-nil ‘finder’ includes directories in its search results.
Whether to abbreviate the user home directory to ’~’.
Maximum abbreviation length, for each directory.
Abbreviate printout if strictly longer than this value. Set to 0 to stop abbreviating.
Call BODY while the POSIX current working directory is set to FILE.
This is just like ‘uiop:with-current-directory’ except that it takes a ‘file’
object.
Return a file predicate that matches on modification time less recent than TIMESTAMP.
Return a file predicate that matches on modification time more recent than TIMESTAMP.
Return a predicate that matches when all the names are contained in the file basename.
Return a predicate that matches when all the path elements are contained in
the file path.
Example:
(file-finder:finder* :predicates (list (every-path~ "file" "lisp")))
;; => (F"file.lisp")
Return a predicate for files that match one of the provided extensions.
Return true if FILE1 and FILE2 point to the same file. They might not be the same objects.
List files in current directory that satisfy all PREDICATE-SPECIFIERS.
Directories are ignored.
Without PREDICATE-SPECIFIERS, list all files.
A predicate specifier can be:
- a string, in which case it is turned into (match-path STRING);
- a pathname, in which case it is turned into (match-path-end PATHNAME);
- a list of predicates, in which case it is turned into (apply #’alexandria:disjoin PREDICATES);
- a function (a predicate).
Passing a list of predicates connects them with a logical OR.
Ignore all directories specified in *exclude-directories* (node_modules).
Examples:
(finder "pred" "lisp") ; => list all files that have these two strings in their path name.
;; => "lisp" matches "quicklisp/local-projects/".
(finder "file" (extension= "lisp")) ; => list all files whose path contain "file" with a ".lisp" extension.
;; =>
(#F"~/quicklisp/local-projects/file-finder/predicates.lisp")
(finder (list "file" (extension= "lisp"))) ; => list all files matching one or the other predicate
; => many more results.
For a more tunable finder, see ‘finder*’.
List FILES (including directories) that satisfy all PREDICATES.
Without PREDICATES, list all files.
Recur in all subdirectories by default.
With RECUR-PREDICATES, recur only in subdirectories that satisfy the list of predicates.
Return a predicate that matches when one of the names matches, case insensitive, the file basename.
Return a predicate that matches when one of the names is contained in the file basename (case insensitive).
Return entries in PATH.
By default, directories come first.
If SORT is non nil, sort them alphabetically.
Second value is the list of directories, third value is the non-directories.
Return a predicate that matches when one of the names matches, case sensitive, the file basename.
Return a predicate that matches when one of the names is contained in the file basename (case sensitive).
Return a predicate that matches when one of the path suffixes matches the file path.
Return a predicate that matches when one of the path elements is contained in
the file path.
Example:
(file-finder:finder* :predicates (list (path~ "file" "lisp")))
;; => (#F"mediafile.lisp" #F"file.lisp" #F"predicates.lisp")
pathname
)) ¶Useful so that ‘path’ can be called both on a ‘file’ or a ‘pathname’. A trailing separator is automatically append for directories, if missing. This is to be consistent with the ‘path’ method for ‘file’.
string
)) ¶Useful so that ‘path’ can be called both on a ‘file’ or a ‘string’.
A trailing separator is automatically append for directories, if missing.
This is to be consistent with the ‘path’ method for ‘file’.
(setf access-date)
.
access-date
.
basename
.
creation-date
.
directory?
.
disk-usage
.
disk-usage*
.
exists?
.
(setf extension)
.
extension
.
file?
.
initialize-instance
.
inode
.
kind
.
link-count
.
(setf modification-date)
.
modification-date
.
parent
.
(setf path)
.
path
.
print-object
.
relative-path
.
size
.
uiop-path
.
string
(error "path required")
:path
path
.
This slot is read-only.
0
This slot is read-only.
file-finder:file-kind
:regular-file
kind
.
This slot is read-only.
0
This slot is read-only.
(local-time:unix-to-timestamp 0)
This slot is read-only.
(local-time:unix-to-timestamp 0)
This slot is read-only.
(local-time:unix-to-timestamp 0)
This slot is read-only.
Return NIL if FILE is not a child of PARENT.
Return a predicate that matches when the argument file is in a subdirectory of ROOT less deep than LEVEL.
If a string is given inside PREDICATES, return a ‘match-path’ predicate.
This allows an easier use of finder*.
Return a predicate that matches when all path elements are contained in the file path.
Useful for ‘finder’ or ‘finder*’, but giving strings one after the other should be sufficient.
Return a predicate that matches when the argument file is in a subdirectory of ROOT less deep than LEVEL.
Return a predicate that matches when one of the path elements is contained in
the file path.
This is the one used when we give a string for predicate.
Useful for ‘finder’.
Return a predicate that matches when one of the path suffixes matches
the file path.
Useful for ‘finder’.
Return true if PARENT is a parent of FILE.
When ABBREVIATE-HOME?, abbreviate user home directory regardless of ABBREVIATION-THRESHOLD.
Jump to: | %
(
A B C D E F G H I K L M N P R S U W |
---|
Jump to: | %
(
A B C D E F G H I K L M N P R S U W |
---|
Jump to: | *
+
A C D I K L M P S |
---|
Jump to: | *
+
A C D I K L M P S |
---|
Jump to: | C F P S T |
---|
Jump to: | C F P S T |
---|