Installing pip/setup in linux


Creating a repo:

For getting repository details please click here 

Click on repo download based on your os version.

Then create a repo file under the below path for centos versions

cd /etc/yum,repos.d/

create any repo file like pip.repo and add the contents to the file

Installing pip tool:

Then run below commands in terminal for installing pip:


  1. sudo yum upgrade python-setuptools
  2. sudo yum install python-pip python-wheel

Example how to use pip to install python bundle:


Usage:


  pip <command> [options]

Commands:
  install                     Install packages.
  uninstall                   Uninstall packages.
  freeze                      Output installed packages in requirements format.
  list                        List installed packages.
  show                        Show information about installed packages.
  search                      Search PyPI for packages.
  wheel                       Build wheels from your requirements.
  help                        Show help for commands.


[client@example ]# pip install pyinotify
 Downloading pyinotify-0.9.6.tar.gz (60kB)
    100% |████████████████████████████████| 61kB 120kB/s
Building wheels for collected packages: pyinotify
  Running setup.py bdist_wheel for pyinotify
  Stored in directory: /root/.cache/pip/wheels/ca/66/27/bba9699a96562cab73cd97e80ca0fc9c1656b757293f889ad4
Successfully built pyinotify
Installing collected packages: pyinotify
Successfully installed pyinotify-0.9.6