diff --git a/README.md b/README.md index a5bac1a..a98539b 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,34 @@ -# pipenvlib -A library for manipulating Pipenv projects. +# PipenvLib: A library for manipulating Pipenv projects. + +This library exists to make it easy to programatically interact with / introspect / manipulate Pipenv projects. + +**It allows you examine depenencies and requirements of a project, as well as install/uninstall packages from Python directly.** + + +## Example Usage + +```python +import pipenvlib + +# Establish where the Pipenv project lives. +project = pipenvlib.PipenvProject('.') + +``` + +```pycon +>>> project.packages +[, ] + +>>> project.locked_package +[, , , ] + +>>> project.install('requests', dev=True) +True + +>>> project.dev_packages +[] +``` + +------------ + +This project (which is a work in progress) was built to facilitate the development of a Sublime Text 3 plugin (which in the works). diff --git a/pipenvlib.py b/pipenvlib.py index 42bc83f..cd1b36f 100644 --- a/pipenvlib.py +++ b/pipenvlib.py @@ -180,7 +180,7 @@ class PipenvProject(object): dev = '' if not dev else '--dev' - return self._run('install {0} {1}'.format(package_name)).return_code == 0 + return self._run('install {0} {1}'.format(package_name, dev)).return_code == 0 def uninstall(self, package_name): """Uninstalls a given package from the pipenv project."""