Expand description
Core file operationscorefil
Statics§
- COMPILED_
GLOB - Cached static for the
compiled_glob
function.
Functions§
- all_
paths_ and_ metadata - A convenience function to return all paths in an Xvc repository. This is meant to be called once in the beginning and the result is carried around instead of hitting the disk every time we look for the changes. It returns the generated XvcPathMetadataMap and IgnoreRules that is created during traversal. NOTE: This function only returns a snapshot of the repository. If you want to handle events after this initial snapshot, see xvc_walker::notify::make_watcher.
- compiled_
glob - Returns a compiled glob::Pattern by prepending it with
pipeline_rundir
. - compiled_
glob_ no_ cache - Origin of the cached function
compiled_glob
. - compiled_
glob_ prime_ cache - Primes the cached function
compiled_glob
. Returns a compiled glob::Pattern by prepending it withpipeline_rundir
. - dir_
includes - Checks whether path is under directory by checking first if it’s in the
pmm
keys - glob_
includes - Checks whether
glob
includespath
. Note that, if thepath
is ignored, this fn always returns false - glob_
paths - Returns all non-ignored paths described with
glob
underroot_dir
- is_
text_ file - Checks whether a file in
path
is a text file by loading the first 8000 bytes (or whole file) and checks if it contains 0 (NUL). The technique is used also by Git. - make_
symlink - Creates a symlink from target to original
- path_
metadata_ channel - w
- pipe_
filter_ path_ errors - Clears errors in
receiver
by ignoring them. TODO:sender
can be ofSender<PathMetadata>