https://github.com/danielthefletch/color50
A lightweight Python package for colorful output at the command line. My final project submission for CS50P at Harvard University.
https://github.com/danielthefletch/color50
cs50 cs50-final-project cs50-python python python-module python-package readthedocs sphinx
Last synced: about 1 month ago
JSON representation
A lightweight Python package for colorful output at the command line. My final project submission for CS50P at Harvard University.
- Host: GitHub
- URL: https://github.com/danielthefletch/color50
- Owner: DanielTheFletch
- License: mit
- Created: 2023-12-21T01:04:24.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2024-01-03T05:48:44.000Z (about 2 years ago)
- Last Synced: 2026-01-06T04:43:38.865Z (about 2 months ago)
- Topics: cs50, cs50-final-project, cs50-python, python, python-module, python-package, readthedocs, sphinx
- Language: Python
- Homepage:
- Size: 6.47 MB
- Stars: 3
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# color50
A lightweight Python package for colorful output at the command line.
Created as a final project submission for Harvard University's CS50P course,
**color50** is a package I designed to add a little extra flavor to standard
output print statements. This is my first ever attempt at making a Python
package from scratch, and I'm excited to share it with fellow Python developers
and CS50 students.
## Included modules
- color
- **Color** class
- core_functions
- ``rgb`` function
- ``hexcode`` function
- ``css`` function
- ``colorize`` function (decorator)
- colorstr
- **ColorStr** class
- constants
## Installation
To install **color50**, execute the following command using the `pip` installer:
```
pip install color50
```
## Sample usage
With **color50** installed, the following code would print `"Hello, World!"` to standard output as purple-colored text.
```py
from color50 import rgb, constants
my_color = rgb(128, 0, 128)
print(my_color + "Hello, World!" + constants.RESET)
```
For more detailed information on using **color50** in your Python projects, please refer to the documentation at [color50.readthedocs.io](https://color50.readthedocs.io/).