2014-02-22 14:58:32 +01:00
|
|
|
# pip
|
|
|
|
|
2016-01-07 18:31:27 +01:00
|
|
|
> Python package manager.
|
2014-02-22 14:58:32 +01:00
|
|
|
|
2016-01-07 18:31:27 +01:00
|
|
|
- Install a package:
|
2014-02-22 14:58:32 +01:00
|
|
|
|
2015-12-28 16:00:21 +01:00
|
|
|
`pip install {{package_name}}`
|
2014-02-22 14:58:32 +01:00
|
|
|
|
2016-01-07 18:31:27 +01:00
|
|
|
- Install a specific version of a package:
|
2015-12-28 14:08:20 +01:00
|
|
|
|
2015-12-28 16:00:21 +01:00
|
|
|
`pip install {{package_name}}=={{package_version}}`
|
2015-12-28 14:08:20 +01:00
|
|
|
|
2016-01-07 18:31:27 +01:00
|
|
|
- Upgrade a package:
|
2014-02-22 14:58:32 +01:00
|
|
|
|
2015-12-28 16:00:21 +01:00
|
|
|
`pip install -U {{package_name}}`
|
2014-02-22 14:58:32 +01:00
|
|
|
|
2016-01-07 18:31:27 +01:00
|
|
|
- Uninstall a package:
|
2014-02-22 14:58:32 +01:00
|
|
|
|
2015-12-28 16:00:21 +01:00
|
|
|
`pip uninstall {{package_name}}`
|
2014-02-22 14:58:32 +01:00
|
|
|
|
2016-01-07 18:31:27 +01:00
|
|
|
- Save installed packages to file:
|
2014-02-22 14:58:32 +01:00
|
|
|
|
|
|
|
`pip freeze > {{requirements.txt}}`
|
|
|
|
|
2016-01-07 18:31:27 +01:00
|
|
|
- Install packages from file:
|
2014-02-22 14:58:32 +01:00
|
|
|
|
2015-10-28 09:33:06 +01:00
|
|
|
`pip install -r {{requirements.txt}}`
|