
Security News
OWASP 2025 Top 10 Adds Software Supply Chain Failures, Ranked Top Community Concern
OWASP’s 2025 Top 10 introduces Software Supply Chain Failures as a new category, reflecting rising concern over dependency and build system risks.
cls-clear: clear your terminal the lazy wayThis is a simple library that provides a command to clear the terminal screen. I am aware of the existance of the clear module; however, this library is aimed at those who have the cls command hardwired into their muscle memory, and want to use it in a python interactive session as well.
Below is a simple comparison; keypress count includes the Enter key, visualized as ↵.
>>> from clear import clear ↵ # 24 keypresses
>>> clear() ↵ # 8 keypresses
Versus:
>>> from cls import * ↵ # 18 keypresses => 25% shorter
>>> cls ↵ # 4 keypresses => 50% shorter
>>> clear ↵ # 6 keypresses => 25% shorter
Life-changing stuff, I know.
The installation and usage is as easy as pie; just install it via pip:
pip install cls-clear
..and then, in an interactive python session, you can just do as such:
PS C:\Users\belliricc\Data\SomeProject> python
Python 3.12.10 (tags/v3.12.10:0cc8128, Apr 8 2025, 12:21:36) [MSC v.1943 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> from cls import *
>>> cls # This will clear the terminal
>>> clear # This will also clear the terminal
If you try to import the library from a non-interactive session (e.g. a script), it will raise an ImportError, for obvious reasons.
This library is very simple; it was developed and tested on Windows 10 and python 3.12, but it should be good to go with python up till 3.0 (checked with vermin) and non-Windows OSs.
Anyways, any feedback is appreciated and welcome; just open an issue or a pull request and I'll gladly take a look at it.
cls-clear is distributed under the Unlicense, which is a public domain dedication. This means that you can do whatever you want with it, including using it in commercial projects, modifying it, and distributing it.
FAQs
A simple program to clear the console screen.
We found that cls-clear demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
OWASP’s 2025 Top 10 introduces Software Supply Chain Failures as a new category, reflecting rising concern over dependency and build system risks.

Research
/Security News
Socket researchers discovered nine malicious NuGet packages that use time-delayed payloads to crash applications and corrupt industrial control systems.

Security News
Socket CTO Ahmad Nassri discusses why supply chain attacks now target developer machines and what AI means for the future of enterprise security.