more details on get_egg_info

This commit is contained in:
Tarek Ziadé 2009-05-14 21:52:58 +00:00
parent aab3dfac57
commit 2b032490c1
1 changed files with 5 additions and 2 deletions

View File

@ -164,13 +164,16 @@ The new functions added in the package are :
- get_egg_info(project_name) -> path or None - get_egg_info(project_name) -> path or None
Scans all site-packages directories and looks for all `project_name.egg-info` Scans all elements in `sys.path` and looks for all directories ending with
directories. Returns the directory path that contains a PKG-INFO that matches `.egg-info`. Returns the directory path that contains a PKG-INFO that matches
`project_name` for the `name` metadata. Notice that there should be at most `project_name` for the `name` metadata. Notice that there should be at most
one result. The first result founded will be returned. one result. The first result founded will be returned.
If the directory is not found, returns None. If the directory is not found, returns None.
XXX The implementation of `get_egg_info` will focus on minimizing the I/O
accesses.
- get_metadata(project_name) -> DistributionMetadata or None - get_metadata(project_name) -> DistributionMetadata or None
Uses `get_egg_info` to get the `PKG-INFO` file, and returns a Uses `get_egg_info` to get the `PKG-INFO` file, and returns a