A redistribution of LilyPond to use it easily from Python code.
Project description
LilyPond wheels
What's this?
GNU LilyPond is a text-based music typesetter.
Wheels are the standard binary distribution format for Python packages. This
repository contains a script that is being used to package LilyPond in wheel
format. The resulting wheels are uploaded on PyPI (see the
lilypond project page). The goal is to make
it easy to use LilyPond from Python code, installing LilyPond as if it were a
normal Python package — which allows to include it in your dependencies, pin it,
makes tools like tox
able to install it, and generally makes all the tooling
around standard Python packages just work.
Usage
If you want to have the LilyPond wrapper package available in your Python environment, you can install it using
pip install lilypond
As always, consider installing packages in a virtual environment instead of globally.
You can of course use it in all the other normal ways a package on PyPI can be
used: pyproject.toml
project.dependencies
list, dependencies in tox.ini
,
requirements.txt
files, etc.
pip install lilypond
does NOT make lilypond
available as a command —
this is normal! This wrapper is specifically intended for using LilyPond from
Python code, not for installing LilyPond in general. In order to use the bundled
LilyPond, you should do:
import subprocess
import lilypond
subprocess.run([lilypond.executable(), "file.ly"])
That is, import the lilypond
module, and use the executable()
function to
get the full path to the bundled lilypond
executable, as a pathlib.Path
object, then use the subprocess
module to execute it.
Scripts shipped with LilyPond are also available; use the optional argument to
executable()
, e.g., executable("convert-ly")
, to access them.
Maintenance
When a new LilyPond release is out, run
hatch run build <version> 0
This leaves wheels of LilyPond <version>
in build/
. If they look good (use a
venv to check), upload them with
python -m twine upload build/*.whl
The 0
in the hatch
command is the build number. In case something goes wrong
in published wheels, fixed wheels should be uploaded with a build number of 1
(then 2
, etc.).
For type checking:
hatch run mypy:check
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distributions
Hashes for lilypond-2.25.11-0-py3-none-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | f0f1db753708eeeee1c8a7f30c57f5bb9691839fb9fa6f4f7849834c680c53c9 |
|
MD5 | 347b04967fd34934ac9c5a91551d7d30 |
|
BLAKE2b-256 | 12ba47e35422d75a07f809c40026d2ba38c79e37568b82dcdbddcfdb36f4aa16 |
Hashes for lilypond-2.25.11-0-py3-none-manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0bd8800624d1166d1aac6c4052c309a4f62b91cf9280e9922f0fd37b3251f0bd |
|
MD5 | 5364c72d325f280b89a5fbf246965ffb |
|
BLAKE2b-256 | f817b0e3e63c71677c297740be9db9d4b5160a21dcc6424801265d022c9b15b8 |
Hashes for lilypond-2.25.11-0-py3-none-macosx_10_15_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7e72210e61cf2191d403a31c17f1bba7c276709792728ee08eb2cff146d3c713 |
|
MD5 | 6d5d67b42bb986cda9779ca5fc48cf13 |
|
BLAKE2b-256 | 23856147ac6bf3eff12f63d567f645ff014480db21318ad7326d8b1bd0e38c2f |