Built-in Python Modules and Command-line Interfaces

Useful built-in Python features to use without any coding.

alpha2phi
6 min readAug 19, 2023
Built-in Python Command-line Interfaces

This article explores interesting built-in Python features that could be useful for Python and non-Python developers.

Getting Started

With Python installed, we can use many of the built-in modules and command-line interfaces without any coding.

We can view more information on a particular command-line interface using the -h option.

For example, to view the help information of the HTTP server module.

python -m http.server -h
View the Help Information

HTTP Server

With a one-liner, we can use Python to create an HTTP server.

This command serves files relative to the current directory, using port 8000.

python -m http.server
A Python HTTP Server

--

--

alpha2phi

Software engineer, Data Science and ML practitioner.