Skip to main content

A cross-platform Python module that provides a clear() function which clears the terminal. That's all.

Project description

clear

A cross-platform Python module that provides a clear() function which clears the terminal. That's all.

To install with pip, run:

pip install clear

You can then clear the screen by running:

from clear import clear
clear()

This function runs the one-liner: os.system('cls' if os.name == 'nt' else 'clear')

This module exists as a simpler alternative to defining this function on your own.

Special thanks to David George for allowing me to use the Clear name on PyPI. The original Clear module ("Command-Line Extract And Rename utility. This provides a media library manager that allows extraction and renaming of media files.") can still be found in the previous releases of this project on PyPI.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

clear-2.0.0.tar.gz (2.1 kB view details)

Uploaded Source

File details

Details for the file clear-2.0.0.tar.gz.

File metadata

  • Download URL: clear-2.0.0.tar.gz
  • Upload date:
  • Size: 2.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.7.1 importlib_metadata/4.8.2 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.10.2

File hashes

Hashes for clear-2.0.0.tar.gz
Algorithm Hash digest
SHA256 fd6d42575ed65063edef3c46e65aa1b3fc05a144dc1691ba62033ffc35f46368
MD5 78b7a8dd6c8359c44f33293403472cce
BLAKE2b-256 17a004e3f6a87245d75956bd254f7e133493ed6e18b49e09c874204cbfe97f42

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page