Download the PHP package elephentity/codegen without Composer

On this page you can find all versions of the php package elephentity/codegen. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package codegen

elephentity-codegen

The code generator for Elephentity.

Implemented in Rust. Build a checkout with cargo build --release --locked, or install the executable on PATH with cargo install --path . --locked. The bin/eleph-codegen checkout launcher uses target/release/eleph-codegen (or a debug build during development). It never falls back to PHP. Installed Cargo binaries need neither PHP nor Cargo to run.

Elephentity compiles human-readable specs into an IR. This program takes it from there: it resolves the language builders a project has configured, runs each one, and signs and writes what they return.

It knows no language. The IR passes through encoded and is never decoded; a builder turns it into PHP or TypeScript or anything else, returns paths and bodies, and this signs and writes them. That keeps one signer as the authority on what "locked" means, rather than every builder reimplementing it and one of them getting it subtly wrong — and it means --check works for every target without a builder knowing --check exists.

docs/PROTOCOL.md is the contract, on both sides.

Commands

generate is run by eleph generate, which compiles the specs and pipes them in. The others are for humans and for tools that need to know what a project generates.

Working on it

Rust sources live in rust/. Each builder owns its IR types and version gate; there is no runtime dependency on the compiler or another builder. PHP in src/ and the bin/eleph-codegen-reference executable is retained as a migration oracle for the existing tests. Production entrypoints run Rust only. PHPStan still checks the reference and acceptance tests at level max.

Compatibility

The JSON protocol, signature format, digest inputs, target resolution order, error pooling, check mode, and extension-scoped cleanup are unchanged. Native subprocess tests cover signed bytes, tampering, nested targets, failed builds, path traversal, and large requests/responses. The original PHP command tests also run against Rust.


All versions of codegen with dependencies

PHP Build Version
Package Version
Requires php Version >=8.3
symfony/console Version ^7.0 || ^8.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package elephentity/codegen contains the following files

Loading the files please wait ...