Skip to main content

Allows users customization of output colour, spacing, and more

Project description

My Output

An aesthetic replacement to print()


Development Status: Early Development

PyPI

About

MyOutput is a Python package that enables users to customize the appearance of standard output (print) and input prompts in the terminal. Currently, the available customization options include coloured text and additional linebreaks.

Supported colours:

  • black
  • red
  • green
  • yellow
  • blue
  • magenta
  • cyan
  • white

and their brighter version with the prefix bright and an underscore (ex. bright_black).

Installation

Use the package manager pip to install MyOutput.

pip install myoutput

Usage

import myoutput

# set print output to yellow
myoutput.set_print_colour("yellow")
print("Hello!")  # Output: (yellow text) Hello!

# set input prompts to red
myoutput.set_input_colour("red")
input("Enter your name: ")  # Prompt appears in red

# return current print output colour
print(myoutput.get_print_colour())  # Output: yellow

# return current input prompt colour
print(myoutput.get_input_colour())  # Output: red

# enable additional linebreak after each print
myoutput.set_linebreak(True)
print("Linebreak test")  # Output: (yellow text, with extra linebreak before)

# restore the original print and input function
myoutput.restore_output()

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

License

MIT

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

myoutput-0.0.1.tar.gz (3.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

myoutput-0.0.1-py3-none-any.whl (3.8 kB view details)

Uploaded Python 3

File details

Details for the file myoutput-0.0.1.tar.gz.

File metadata

  • Download URL: myoutput-0.0.1.tar.gz
  • Upload date:
  • Size: 3.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.2

File hashes

Hashes for myoutput-0.0.1.tar.gz
Algorithm Hash digest
SHA256 fb26243ab59a713ae4ee0cedbd2c2ee09fa54503aad52df1de31e023dadbf394
MD5 98dbe5964e84e7b60ead7e31008fce34
BLAKE2b-256 34f947f46016665e1aad36518ffdf9f9c996f6c6afea9d1c0f4989aa3e9bd3b7

See more details on using hashes here.

File details

Details for the file myoutput-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: myoutput-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 3.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.2

File hashes

Hashes for myoutput-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 5a52c2ca67435551d43fa6913d98107988973218debd1d3b0e35df3e8668ec7b
MD5 aa5b50dcf7f1558ceb143ce729583c50
BLAKE2b-256 791683bddc1a2f3b61f245040cffcbaf79a100c0315b01350ff221f91aa420bd

See more details on using hashes here.

Supported by

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