Version: 5.1.1
9 Directories
This library is
unstable;
compatibility will not be maintained.
See
Unstable for more information.
This library defines utilities dealing with the directory paths used by the
Racket distribution.
Produces a string rendering of path, replacing distribution-specific
paths (normally: collections, user-installed collections, or PLanet cache) with
short abbreviations.
The set of paths and their abbreviations may be overridden by the
#:dirs option, which accepts an association list. Its keys must be
thunks which produce a path. Its values may be either #f for no
abbreviation (the directory prefix is simply omitted) or any other value to be
displayed in the output. For instance, "document.txt"
relative to a path abbreviated "path" would be rendered as
"<path>/document.txt".
If the path is not relative to one of the given directories, the default return
value is a string rendering of the unmodified path. This default may be
overridden by providing default.
Examples: |
| "source/project.rkt" | | "<collects>/unstable/source/project.rkt" | | "/source/project.rkt" | | #f | | "<src>/project.rkt" |
|
Represents the default directory substitutions for
path->directory-relative-string. By default, the collections directory
is replaced by
collects, the user-installed collections directory
is replaced by
user, and the PLaneT cache is replaced by
planet.
Represents the directory substitutions used by setup-plt. The
collections directory is omitted, the user-installed collections directory is
replaced by user, and the PLaneT cache is replaced by
planet.