Python Pip
PIP is the tool that installs and manages Python packages (you can also think of them as modules).
Note: PIP comes bundled with Python from version 3.4 onward.
What is a Package?
Modules are libraries of Python code that you can add to a project. A package bundles every file a module needs.
Check if PIP is Installed
From the command line, go to Python's script directory and run this command:
pip --version
Install PIP
Missing PIP? It is available to download and install at this address: https://pypi.org/project/pip/
Download a Package
Getting a package takes very little effort.
All you do is ask PIP for it from the command line: go to Python's script directory and enter the following command:
pip install camelcase
Using a Package
As soon as the installation finishes, the package is ready for you to use.
Just import "camelcase" into your project.
Example
A short program that imports "camelcase" and uses it:
Output: complete Python program
import camelcase
c = camelcase.CamelCase()
txt = "hello world"
print(c.hump(txt))
Find Packages
You can find more packages at https://pypi.org/.
Remove a Package
Removing a package takes the uninstall command:
PIP then asks whether you really want camelcase gone.
Answer with y to finish the removal.
pip uninstall camelcase
List Packages
To see every package installed on your system, run the list command:
pip list