Walk a filesystem subtree.
The function to be executed on each file.
The function to be executed on each file.
The return value walkDirection
shall be one of the following:
1
to descend into the subtree,0
to NOT descend into the subtree of fi
,-1
to stop walking alltogether, in which case .walk()
will return immediately.By default, walk does not descend into imported subtrees.
Pass in true
to enable descending.
Walk a filesystem subtree. Import links are not followed by default, but can be followed optionally.
The callback function is first called on the file itself.
Basic example.
Do not descend into the subtree of f1.
Find the file named f1, then stop walking immediately.