Python PIP

Sebelum masuk ke pembahasan terkait Modul, Paket, dan Library penting memahami Python PIP atau package manager dalam bahasa pemograman python.

What is a Package (PIP)?

Package Manager adalah alat bantu yang digunakan untuk:

  • Mengelola library atau modul tambahan yang dibutuhkan oleh suatu bahasa pemrograman.

  • Mengunduh, menginstal, menghapus, atau memperbarui package (perpustakaan) dengan mudah.

Check if PIP is Installed?

C:\Users\Python36-32\Scripts>pip --version

Install PIP?

If you do not have PIP installed, you can download and install it from this page: https://pypi.org/project/pip/

Download a Package

Downloading a package is very easy.

Open the command line interface and tell PIP to download the package you want.

Navigate your command line to the location of Python's script directory, and type the following:

Example

Download a package named "camelcase":

pip install camelcase

Find Packages

Find more packages at https://pypi.org/.

Remove a Package

Use the uninstall command to remove a package:

Example

Uninstall the package named "camelcase":

Python36-32\Scripts>pip uninstall camelcase

List Packages

Use the list command to list all the packages installed on your system:

Example

List installed packages:

Python36-32\Scripts>pip list
Package         Version
-----------------------
camelcase       0.2
mysql-connector 2.1.6
pip             18.1
pymongo         3.6.1
setuptools      39.0.1

Pertanyaanya adalah? Apakah wajib menginstall PIP jika menggunakan bahasa pemograman python?

Last updated