PHPackages                             phpgt/gtcommand - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [CLI &amp; Console](/categories/cli)
4. /
5. phpgt/gtcommand

ActiveLibrary[CLI &amp; Console](/categories/cli)

phpgt/gtcommand
===============

Provides the `gt` command for automating WebEngine development.

v1.2.0(1mo ago)01.9k[11 issues](https://github.com/PhpGt/GtCommand/issues)[2 PRs](https://github.com/PhpGt/GtCommand/pulls)1PHPPHP &gt;=8.3CI passing

Since Oct 9Pushed 2w ago1 watchersCompare

[ Source](https://github.com/PhpGt/GtCommand)[ Packagist](https://packagist.org/packages/phpgt/gtcommand)[ GitHub Sponsors](https://github.com/sponsors/phpgt)[ RSS](/packages/phpgt-gtcommand/feed)WikiDiscussions master Synced 3w ago

READMEChangelog (7)Dependencies (16)Versions (21)Used By (1)

Provides the `gt` command for automating WebEngine development.
===============================================================

[](#provides-the-gt-command-for-automating-webengine-development)

This repository holds the CLI functionality for [PHP.Gt/WebEngine](https://www.php.gt/webengine), exposed via the `gt` command line.

The following commands are exposed:

- `gt add` - add a page, API endpoint or cron script from a template
- `gt create` - create a new WebEngine application
- `gt test` - run configured PHP and JavaScript test suites
- `gt serve` - run the inbuilt development server
- `gt build` - compile client-side assets
- `gt cron` - invoke scripts or static functions at regular intervals
- `gt run` - run all background scripts at once - a combination of `serve`, `build --watch` and `cron --watch --now`
- `gt deploy` - instantly deploy your application to the internet

`gt add`
--------

[](#gt-add)

Use `gt add type name [template]` to create new files in the current project.

Supported types:

- `page`
- `api`
- `cron`

Examples:

- `gt add page about`
- `gt add api users`
- `gt add cron cleanup`
- `gt add page about multi-column`

`type` and `name` are required. `template` is optional.

### Built-in templates

[](#built-in-templates)

If no template name is provided, `gt add` copies the built-in templates from this package:

- `src/Template/page/template.html` -&gt; `page/.html`
- `src/Template/page/template.php` -&gt; `page/.php`
- `src/Template/api/template.php` -&gt; `api/.php`
- `src/Template/api/template.json` -&gt; `api/.json`
- `src/Template/cron/template.php` -&gt; `cron/.php`

If a template file contains `{{name}}`, it is replaced with the provided `name`.

### Project templates

[](#project-templates)

If a template name is provided, files are loaded from the current working directory instead:

- `/_template/.*`

For example:

- `gt add page about multi-column`

This will copy:

- `page/_template/multi-column.html` -&gt; `page/about.html`
- `page/_template/multi-column.php` -&gt; `page/about.php`

The same lookup rule applies for `api`, `cron`, and future types that may be added later.

Proudly sponsored by
====================

[](#proudly-sponsored-by)

[JetBrains Open Source sponsorship program](https://www.jetbrains.com/community/opensource/)

[![JetBrains logo.](https://camo.githubusercontent.com/b5639e7738c6dfae9fe3f3e20175570b7376ce2577a772e09c25c2d4f14bf86e/68747470733a2f2f7265736f75726365732e6a6574627261696e732e636f6d2f73746f726167652f70726f64756374732f636f6d70616e792f6272616e642f6c6f676f732f6a6574627261696e732e737667)](https://www.jetbrains.com/community/opensource/)

###  Health Score

53

—

FairBetter than 96% of packages

Maintenance95

Actively maintained with recent releases

Popularity18

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity75

Established project with proven stability

 Bus Factor1

Top contributor holds 94.4% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~280 days

Recently: every ~337 days

Total

7

Last Release

36d ago

Major Versions

v0.1.0 → v1.0.02021-11-08

PHP version history (3 changes)v0.1.0PHP &gt;=8.0

v1.1.0PHP &gt;=8.2

v1.1.2PHP &gt;=8.3

### Community

Maintainers

![](https://www.gravatar.com/avatar/9e42344b91ce4b91ab57875969f67a0a6a48de570a08bc65d673b06b72fd3a3f?d=identicon)[g105b](/maintainers/g105b)

---

Top Contributors

[![g105b](https://avatars.githubusercontent.com/u/358014?v=4)](https://github.com/g105b "g105b (17 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (1 commits)")

---

Tags

automationdeveloper-experienceergonomicsno-aiphp

###  Code Quality

Static AnalysisPHPStan

Code StylePHP\_CodeSniffer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/phpgt-gtcommand/health.svg)

```
[![Health](https://phpackages.com/badges/phpgt-gtcommand/health.svg)](https://phpackages.com/packages/phpgt-gtcommand)
```

###  Alternatives

[seld/cli-prompt

Allows you to prompt for user input on the command line, and optionally hide the characters they type

24726.4M22](/packages/seld-cli-prompt)[illuminate/console

The Illuminate Console package.

13045.3M6.2k](/packages/illuminate-console)[phpgt/webengine

Minimalistic, ergonomic PHP toolkit.

2622.2k](/packages/phpgt-webengine)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
