njinja
njinja is a general-purpose lightweight meta-build system for
Ninja.
It is for people who:
-
need the flexilibity of
make(1)(e.g. wildcards) but want to migrate away from its unclean language -
need the lightweight and principled design of
ninja(1)but need a equally lightweight (and principled) way to generate its build files -
have an unusual project structure that cannot be cleanly handled by other common meta-build systems for ninja, that are too special-purpose or focus on a particular programming language that isn't what your project actually uses.
Install via pip:
$ pip3 install -U njinja
Usage
-
Write your Ninja build file as a Jinja template, named (e.g.)
build.ninja.j2. Within this template, you may refer to variables that contain build inputs that cannot be known (or are inconvenient to know) in advance. -
Write a python build script, named (e.g.)
build.py, that uses ournjinjalibrary to calculate these build inputs, populate the template with them, create abuild.ninjafile, and call ninja on this file all in one step.
See here for our basic example, that showcases a few different ways of calculating these build variables. Adapt this to whatever is suitable for your project.
Metadata
Release files for njinja 0.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| njinja-0.3.tar.gz | 5.3 kB | Without provenance | Details for njinja-0.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| njinja-0.3-py3-none-any.whl | Python 3 | none | any | Details for njinja-0.3-py3-none-any.whl |
Total release size: 10.5 kB
Release files / njinja-0.3.tar.gz
| Download URL | njinja-0.3.tar.gz |
|---|---|
| Size | 5.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ed312120326d095243c15c0984f5538f530efb6d1bfc6a2ffc63b6f8b5f0605b
|
|
BLAKE2b-256 checksum How to use checksums |
5db487cb8915ead6f7043b27e777abc9d7eed72548d359e19c396bcd6d33eec3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.7
|
Release files / njinja-0.3-py3-none-any.whl
| Download URL | njinja-0.3-py3-none-any.whl |
|---|---|
| Size | 5.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f2e36ddbd4348cb865ae2a1be886fc780f8530a914a18a69edfe25ee63bfac43
|
|
BLAKE2b-256 checksum How to use checksums |
2c3b646e0e14f7678dc7f2b6291fdb4feb47b423fdd2b2478d7dde8e29348fde
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.7
|
Security for njinja 0.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.