Skip to main content

python-chordpro

python-chordpro is a ChordPro parser, written in Python. The main difference between this module and other similar libraries is that python-chordpro parses ChordPro files down to the syllable level, enabling finer-grained control of the formatted output.

Installation

You can use pip to install python-chordpro:

$ pip install python-chordpro

Example Usage

from chordpro import Song

song = Song('path/to/song.chordpro')

for verse in song.verses:
    print(verse.title)

Rendering

python-chordpro comes with two renders, HTML and Text.

from chordpro.renderers.html import render

print(render(song))

Command Line Interface

python-chordpro also ships with a built-in command line interface which will read a ChordPro file and then render it using either the text or HTML renderer.

For example:

$ python-chordpro path/to/song.chordpro -f text -o song.txt

License

python-chordpro is licensed under the MIT license. See the LICENSE file for more information.

Metadata

Release files for python-chordpro 0.0.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for python-chordpro 0.0.2
File Size Uploaded
python-chordpro-0.0.2.tar.gz 8.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for python-chordpro 0.0.2
File Interpreter ABI Platform
python_chordpro-0.0.2-py2.py3-none-any.whl Python 2, Python 3 none any Details

Total release size: 18.4 kB

Release files / python-chordpro-0.0.2.tar.gz

Download URL python-chordpro-0.0.2.tar.gz
Size 8.8 kB
Tags Source
SHA-256 checksum
How to use checksums
13263e171831e8c96ea703564e063d7fc00ff0a58ff5b7d4a780b3e9e05f6efe
BLAKE2b-256 checksum
How to use checksums
8132240281e132d9742a031dcd7c89f2a71b012a5d0588a74c7222b96e0a5a4d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.4.2 importlib_metadata/4.6.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.9.2

Release files / python_chordpro-0.0.2-py2.py3-none-any.whl

Download URL python_chordpro-0.0.2-py2.py3-none-any.whl
Size 9.6 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
5b82841455ea29a9f0aa27b5abd2ce4adc255838ae11103aacf8ef3d1f7bd060
BLAKE2b-256 checksum
How to use checksums
7df077168bf6480c7aedad9c897a6feceea6e693be341be7248d29959a697380
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.4.2 importlib_metadata/4.6.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.9.2

Release history Release notifications | RSS feed

This release

0.0.2 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page