Skip to main content

A Python library for generating ASCII art from text

Project description

asciigenator

A lightweight Python library for generating ASCII art from text.

PyPI version Python Versions License Python application Coverage

Table of Contents


Installation

  • Clone the repository:

    git clone https://github.com/bhatishan2003/asciigenator.git
    cd asciigenator
    
  • Install the package:

    pip install .
    
  • For development (editable mode):

    pip install -e .
    

Usage

Basic Python Usage

import asciigenator

# Test simple font
print("=== Simple Font ===")
print(asciigenator.generate("Hello", font="simple"))

# === Simple Font ===
#  *   **  ** *** ***  ** *** *   *
# * * *   *    *   *  *   *   **  *
# ***  *  *    *   *  * * **  * * *
# * *   * *    *   *  * * *   *  **
# * * **   ** *** ***  ** *** *   *

print("\n=== Block Font ===")
print(asciigenator.generate("Ishan", font="block"))

# === Block Font ===
#   █
#  █ █  ████  ████ █████ █████  ████ █████  █   █
#  █ █  █     █       █     █   █     █     ██  █
# █████  ███  █       █     █   █  ██ ████  █ █ █
# █   █     █ █       █     █   █   █ █     █  ██
# █   █ ████   ████ █████ █████  ████ █████ █   █

print("\n=== Available Fonts ===")
print(asciigenator.list_fonts())

# === Available Fonts ===
# ['block', 'simple']

Command Line Usage

asciigenator "Hello World"
asciigenator "Hello World" --font block
asciigenator --list-fonts
asciigenator "Hello World" --font block  --border "#"
asciigenator "Hello World"  --font block --color magenta

Testing

Run all tests:

pytest -v

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

asciigenator-0.0.4.tar.gz (8.6 kB view details)

Uploaded Source

Built Distribution

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

asciigenator-0.0.4-py3-none-any.whl (6.9 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: asciigenator-0.0.4.tar.gz
  • Upload date:
  • Size: 8.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for asciigenator-0.0.4.tar.gz
Algorithm Hash digest
SHA256 669ea6e52946e4cd6edfaba694244e38da4753026495f4fae993786dca804d83
MD5 afa82155015c65bf7c23e154b2e8cd36
BLAKE2b-256 1ad37dfb7cbd93fde82ba3054899144264a7e789dd8414c6fcbac5792e65d80a

See more details on using hashes here.

File details

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

File metadata

  • Download URL: asciigenator-0.0.4-py3-none-any.whl
  • Upload date:
  • Size: 6.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for asciigenator-0.0.4-py3-none-any.whl
Algorithm Hash digest
SHA256 57ae5ee9b5d69e5576a1bfe827a60ed27ec80848faf8654beaac6ccb6a978118
MD5 6ea134eeef2530b743097c5f67d86753
BLAKE2b-256 cde20be793c4fb06f943babcb008270725279361cf322adb48c5311df5e9ba60

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