Skip to main content

Cowser

Logo

A fun command-line tool that greets you with ASCII art cows. Inspired by cowsay, written in Python.

Features

  • Greet users with a random ASCII art cow
  • Pick a specific cow by name or index
  • Custom messages and piping from stdin
  • Colored output (and --no-color for scripts)
  • Easy to extend with new cow designs

Installation

Requires Python 3.8+.

From PyPI

pip install cowser

From source

git clone https://github.com/rkriad585/Cowser
cd Cowser
pip install -r requirements.txt
pip install .

Usage

The cowser command is installed on your PATH. The original python main.py ... and ./cowset ... invocations still work too.

Greet a user

cowser Alice
 _________
/ Hi Bob! \
\__________/
  ______
 /      \
|  (o) (o)
|   \/
 \______/

Custom message

cowser --message "Hello, world!"

Pipe text via stdin

echo "From stdin" | cowser

Pick a specific cow

cowser --cow top-hat Bob
cowser --cow 3 Bob

Names can be shortened to a unique prefix, e.g. --cow top.

Other options

Option Description
--cow NAME_OR_INDEX Choose a cow by name or index.
--list List all available cows.
--message TEXT Show a custom message instead of a greeting.
--color COLOR Output color (default: cyan).
--no-color Disable colored output.
-h, --help Show help.
-V, --version Show version.

Legacy commands

Backwards-compatible with the original script:

python main.py Alice
python main.py help
python main.py list
./cowset Alice

Adding more cows

Open cowser/cows.py and add a (name, art) tuple to the COWS list:

("my-cow", r"""   /\
  /  \
 | oo |
 ~~   ~~"""),

Use cowser --cow my-cow --list to verify it renders.

License

MIT © 2026 rkriad585

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cowser-1.0.0.tar.gz (5.9 kB view details)

Uploaded Source

Built Distribution

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

cowser-1.0.0-py3-none-any.whl (7.3 kB view details)

Uploaded Python 3

File details

Details for the file cowser-1.0.0.tar.gz.

File metadata

  • Download URL: cowser-1.0.0.tar.gz
  • Upload date:
  • Size: 5.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.12.7

File hashes

Hashes for cowser-1.0.0.tar.gz
Algorithm Hash digest
SHA256 01b06f3d9e70cc2c171239e5f45002d81735d224be36df98cca1181e03651926
MD5 aeeefac15d5638c316c85ae2a8b09ae6
BLAKE2b-256 5bd81db25b5cc333aafde33e2ece1441fd5b5ca504b104a570733040f531225d

See more details on using hashes here.

File details

Details for the file cowser-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: cowser-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 7.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.12.7

File hashes

Hashes for cowser-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 ae0039d76c8206b9d753dbdcf6426443762056cd108619e3b3918d2dee772bbf
MD5 9ce50646bd36c92d6aabd6fb67011e78
BLAKE2b-256 f1adc9770d5aae0c847dc9ec526eb4e568123449d9e78123e828598918c3e8c9

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