Install Python and pip packages and related commands in Linux
>>> Ora 23 is updated with python 2,. 7.11.3, but for python package installation, pip package is required to manage python package resources.
Pip package installation.
The methods for python2.x and python 3.x are different:
Python 2:
Sudo dnf upgrade python-setuptools
Sudo dnf install python-pip python-wheel
Python 3: sudo dnf install python3 python3-wheel # python3 comes pip
Pip command:
Pip install SomePackage # install a package (Latest Version)
Pip install somepackage = 1.4 # install a package in version 1.4
Pip show -- files SomePackage # view installed packages
Pip install -- upgrade SomePackage # update a package
Pip uninstall SomePackage # uninstall a package
Pip install SomeProject> = 1, <2 # install packages between two versions
Pip install 'someproject ~ = 1.4.2 '# Install a package of a similar version
Pip install -- index-url http://my.package.repo/simple/ SomeProject # url Installation
# Install another one at the same time
Pip install -- extra-index-url http://my.package.repo/simple SomeProject
# Local src tree Installation
Pip install-e or
Pip install
Pip install./downloads/SomeProject-1.0.4.tar.gz # local archive Installation
# Install from the local directory (3)
Pip install -- no-index -- find-links = file: // local/dir/SomeProject
Pip install -- no-index -- find-links =/local/dir/SomeProject
Pip install -- no-index -- find-links = relative/dir/SomeProject
Pip install -- pre SomeProject # pre-install as required.
$ Pip install SomePackage [PDF] $ pip install SomePackage [PDF] == 3.0 $ pip install-e. [PDF] == 3.0 # editable project in current directory
Main sources:
Https://packaging.python.org/en/latest/install_requirements_linux/#installing-pip-setuptools-wheel-with-linux-package-managers
Https://packaging.python.org/en/latest/installing/#installing-from-vcs
Python core programming version 2. (Wesley J. Chun). [Chinese version of hd pdf]
Python development technology details. (Zhou Wei, Zong Jie). [hd PDF scan version + book guide video + code]
Use Python for file backup
Obtain Linux information using a Python script
Build a desktop algorithm transaction research environment using Python in Ubuntu
Python details: click here
Python: click here
This article permanently updates the link address: