Expand description
Finding installed plugin packages.
A project’s plugins live in <project>/dre_deps/plugins, hard-linked (or copied) from a shared
download cache in ~/.dre/plugins. DRE_PLUGINS_DIR replaces both. Inside a plugins
directory, packages sit side by side by version, <dir>/<package>/<version>/, holding the
package’s executable and a MANIFEST naming it and the plugins it provides, as installed by
the plugin manager. Executables placed by hand (development, tests) sit flat in the directory:
dre-plugin-<package>, or dre-<kind>-<name> for a package of that one plugin, called <name>.
Structs§
- Installed
Package - Located
- The executable to start for one plugin, and the plugin to ask it for.
- Manifest
- An installed version’s
MANIFEST.
Enums§
- Locate
Error - Why
locatefound nothing.
Constants§
- DEPS_
DIR - Everything a project installs: plugins and macro packages.
- MANIFEST
- What an installed version’s directory holds besides the executable.
Functions§
- cache_
dir - The shared download cache, which project installs link from; also where
dre initinstalls before a project exists. - check_
uses - Check that a declared package provides every plugin the project uses: from the installed
packages, else from
dre.lock. A package that’s neither installed nor locked is already an install error, so plugins it might provide aren’t reported again. - discover
- Every package under
dir, flat ones first, then versioned ones in version order. - find
- The installed copies of package
nameto use: an exactpinif given, otherwise the highest installed version matchingreq; failing both, the flat (hand-placed) executables of that name. Several only when a package is placed flat as onedre-<kind>-<name>per plugin. - legacy_
executable - The executable file name a package installs under when its archive holds a single plugin’s
dre-<kind>-<name>(a plugin built before packages). - link_
or_ copy - Put
srcatdstwithout a second copy on disk where possible. - link_
version - Link (or copy) an installed version’s directory, executable and manifest, from one plugins directory to another.
- locate
- Find the plugin
idamong the project’s declared packages. - locate_
in locate, given the project’s root and declared packages.- override_
dir DRE_PLUGINS_DIR, when set: plugins live and install there, for every project.- plugins_
dir - Where a project’s plugins live (
None: outside any project, the cache). - probe
- The plugins an executable serves, from its name when that’s
dre-<kind>-<name>, else from its handshake. Asked once per file and modification time. - read_
manifest - version_
dir - Where a versioned install of a package lives.
- write_
manifest