Skip to main content

A simple package for helpful python terminal outputs

Project description

py-term-helper

Overview

The py-term-helper is a lightweight Python terminal debug helper tool designed to streamline the debugging process for developers. Creates a more dynamic output for the terminal with star lines and any console testing visuals. It provides essential functions and utilities to assist in identifying and resolving issues in Python applications directly from the terminal.

Features

  • .term_size:

    • Returns current size of terminal in characters
  • .star_line(char="*") :

    • Prints terminal wide char
  • .center_string_stars(string, char="*") :

    • Prints the string in the center of terminal wide char
  • .term_wrap(string, char="*") :

    • Prints the string in the center of terminal wide char with 2 .star_line above and below
    • Essentially: .star_line() => .center_string_stars() => .star_line()
  • .topwrap(string, char="*") :

    • Clears console and runs .term_wrap()
  • .kv_print(arg) :

    • Prints any given arg as '{arg_variable_name} => {arg_value}'
    • Similar to JavaScript's console.log({ arg }) => "{arg_name: arg_value}"

Getting Started

  1. Installation:

    pip install py-term-helper
    
  2. Usage:

from py_term_helpers import TermHelper

TermHelper.term_wrap("Terminal Wrap")
# Output:
# *************************************Terminal Wrap**************************************

TermHelper.star_line()
# Output:
# *************************************************************************************

my_dict = dict({'key': 'value'})
TermHelper.kv_print(my_dict)
# Output:
# 

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

py_term_helpers-0.0.4.tar.gz (3.1 kB view details)

Uploaded Source

Built Distribution

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

py_term_helpers-0.0.4-py3-none-any.whl (3.2 kB view details)

Uploaded Python 3

File details

Details for the file py_term_helpers-0.0.4.tar.gz.

File metadata

  • Download URL: py_term_helpers-0.0.4.tar.gz
  • Upload date:
  • Size: 3.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.8.13

File hashes

Hashes for py_term_helpers-0.0.4.tar.gz
Algorithm Hash digest
SHA256 df209caa6840ca9d45feeb44f09ed1d41623aea6175691bcc8d61ec0d200c275
MD5 0f954f24f378062c6f6a62b2cdde1d30
BLAKE2b-256 493c1c6571d85a83f77ac7a5f726b8eb2c9f9adb217f13531a516a67a661350e

See more details on using hashes here.

File details

Details for the file py_term_helpers-0.0.4-py3-none-any.whl.

File metadata

File hashes

Hashes for py_term_helpers-0.0.4-py3-none-any.whl
Algorithm Hash digest
SHA256 f9b29cbd3bdfde9806d034a2a07bd6c5fda973e09c7a5403ebb8f7b3b7859bca
MD5 0797e6403d71c3e2a2c5d0cf0b8498d2
BLAKE2b-256 8ef870b76103609ab6243c1ca815fb5116c11c5a46701715d6f7d9368810e19d

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