Skip to main content

Genmax

Genmax is a simple code generation tool.

Key Components

  • Workflows

Genmax projects have workflows to group together multiple files to be generated. Flows are in yaml.j2 format.

  • Data

You can pass data to templates and workflows that help generate data. For example, you can dynamically pass the name of attributes if you are generating a class file.

  • Templates

These templates form the basis of the code to be generated. Genmax uses the Jinja2 engine for code generation.

  • Output

Once the data is passed to a template, Genmax generates an output file with the generated code. For nested output locations, you can use > as a separator.

Commands

Command Description
gmx init Initialize genmax in the current folder.
gmx run <workflow-name> Run a workflow.

Extensions supported in templates

The following methods are supported in the template:

Description Method
Lower case first char lcase(your_string)
Lower case lowercase(your_string)
Upper case uppercase(your_string)
Pluralize pluralize(your_string)
Join With Commas joinify(name_of_element, element_list)
Switch to Camel case camel(your_string)
Switch to Kebab case kebab(your_string)
Switch to Pascale case pascale(your_string)
Switch to Dot case dot(your_string)
Switch to Title case title(your_string)
Switch to Snake case snake(your_string)
Switch to Path format path(your_string)
Generate UUID uuid()
Generate secret in 16 bit - hexadecimal secret()
Generate secret in 64 bit - hexadecimal secret_complex()
Read config from .env file. env(file_name, config_name)

Quick Start

Create a sample project.

gmx init

Run the sample workflow.

gmx run sample

Workflow Item Types

Add these to your workflow YAML file as needed.

Item Description
Generate
data Data to pass to the template.
action The name of the generate action.
template Template to use for code generation (j2 supported).
output Name and extension of the output file.
Write to File
action The name of the write_to_file action.
template Template to write to file.
output Name and extension of the output file.

Metadata

Release files for genmax 0.1.9

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

Source distribution (sdist)

Source distribution for genmax 0.1.9
File Size Uploaded Provenance Actions
genmax-0.1.9.tar.gz 11.6 kB Without provenance Details for genmax-0.1.9.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for genmax 0.1.9
File Interpreter ABI Platform Actions
genmax-0.1.9-py3-none-any.whl Python 3 none any Details for genmax-0.1.9-py3-none-any.whl

Total release size: 29.7 kB

Release files / genmax-0.1.9.tar.gz

Download URL genmax-0.1.9.tar.gz
Size 11.6 kB
Tags Source
SHA-256 checksum
How to use checksums
c00c099d691b297796ca838eaf1df5f0af3916db2c9770d010542cbd4919f713
BLAKE2b-256 checksum
How to use checksums
15b27dc8a712a847b49dfffe5dc3529d1a75b2020bf6303e646bc5be3ad8ec37
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.10.14

Release files / genmax-0.1.9-py3-none-any.whl

Download URL genmax-0.1.9-py3-none-any.whl
Size 18.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
729e001d8fdb2be508555a90240872b01f2b16b07d90d0aa8a3510317ce2b35a
BLAKE2b-256 checksum
How to use checksums
ceead0b4a164d0dbed320093b82a245448b5c54efdef650254f93f8013f44049
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.10.14

Security for genmax 0.1.9

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.

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