Download the PHP package gemvc/cli-base without Composer
On this page you can find all versions of the php package gemvc/cli-base. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download gemvc/cli-base
More information about gemvc/cli-base
Files in gemvc/cli-base
Package cli-base
Short Description Internal GEMVC CLI foundation: terminal I/O, filesystem helpers, and codegen abstract base classes. For GEMVC ecosystem only.
License MIT
Informations about the package cli-base
gemvc/cli-base
Internal package for the GEMVC framework. It provides shared CLI primitives: typed terminal colors (CliColor), line/box drawing (CliLine), command base (Command), filesystem helpers (FileSystemManager), boxed output (CliBoxShow), codegen abstracts, and install smoke check (InstallControl).
For AI coding assistants (mandatory)
Before you modify code, tests, composer.json, or documentation in this repository, read AI-Assistant.md from top to bottom. That file is the canonical source for:
- GEMVC framework context (HTTP four-layer architecture, CLI discovery, folder layout, how to ship compatible extra CLI packages)
- Quick API reference (every class, method, return type, and short behavior notes)
- Architecture boundaries (what belongs here vs in
gemvc/library) - Template resolution, Composer constraints, testing, and distribution (
archive/export-ignore)
If README.md and AI-Assistant.md disagree, treat AI-Assistant.md as authoritative.
GEMVC architecture (short)
GEMVC is a PHP REST API framework with a fixed four-layer flow (each layer has a clear job; do not skip layers):
| Layer | Typical folder | Role |
|---|---|---|
| API | app/api/ |
HTTP entry, schema validation, auth checks; classes extend ApiService. |
| Controller | app/controller/ |
Orchestrates use cases; calls models. |
| Model | app/model/ |
Business rules, validation, transformations. |
| Table | app/table/ |
Database access via the framework Table / query builder. |
HTTP routing: there are no hand-written route files. URLs map by convention, e.g. /api/{ServiceName}/{methodName} → class in app/api/ and method on that class (see GEMVC docs / main repo .cursorrules).
GEMVC CLI commands (short)
The gemvc executable ships with gemvc/library (e.g. vendor/bin/gemvc). It loads Composer’s autoloader, parses argv[1] as the command, and maps names like create:service to a PascalCase class name (CreateService) by splitting on : and uppercasing each segment.
Search order (simplified):
- Framework commands — namespace
Gemvc\CLI\Commands\, PHP files undervendor/gemvc/library/src/CLI/commands/(or the monoreposrc/CLI/commands/when developing the framework). - Project commands — namespace
App\CLI\Commands\, files underapp/CLI/commands/in the application repo (yourcomposer.jsonmust autoload that namespace).
The dispatcher does new $commandClass($remainingArgv) then execute(). Commands are plain PHP classes; gemvc/cli-base supplies shared bases (Command, FileSystemManager, CliBoxShow, generator abstracts) so framework and custom commands share the same terminal and filesystem behavior. Colors use the CliColor enum (not string color names).
Where this package fits: gemvc/cli-base is the small dependency with those bases; gemvc/library holds bin/gemvc, concrete Gemvc\CLI\Commands\* implementations, init flows, and HTTP/runtime code.
README vs AI-Assistant.md (where to put detail)
| Doc | Purpose |
|---|---|
README.md |
Short orientation: what GEMVC is, how CLI discovery works, install pointer, mandatory link for AIs to AI-Assistant.md. |
AI-Assistant.md |
Full API tables, template rules, Composer boundaries, testing, distribution, and deeper notes on extending GEMVC and designing compatible CLI packages (including limits of the stock gemvc binary). |
Put long architecture and “how to build another CLI package” guidance in AI-Assistant.md so one file stays authoritative; keep README.md skimmable.
Human summary
- Not a supported public API for arbitrary third-party packages.
- Does not depend on
gemvc/library(avoids circular Composer dependencies). - Template fallbacks resolve
gemvc/libraryvia Composer’sInstalledVersionswhen templates are not in the project.
Install with the main framework:
(gemvc/library 5.7+ declares a dependency on gemvc/cli-base.)
Development (this repo)
Coverage is configured in phpunit.xml (<source> → src/). See AI-Assistant.md for the full API, template rules, and architecture boundaries.
All versions of cli-base with dependencies
composer-runtime-api Version ^2.2
ext-mbstring Version *