hyde / cli
The HydePHP CLI - a portable static site generator that runs without PHP or Composer.
Requires
- php: ^8.2
- hyde/framework: dev-master
- hyde/realtime-compiler: dev-master
- laravel-zero/framework: ^11.0
Requires (Dev)
- mockery/mockery: ^1.6
- pestphp/pest: ^3.0
Suggests
- ext-curl: Required for using the self-update feature when not installing through Composer.
Provides
None
Conflicts
None
Replaces
None
This package is auto-updated.
Last update: 2026-08-31 00:15:13 UTC
README
About
The HydePHP CLI is a single-file executable for the static site generator HydePHP.
It carries its own PHP runtime, its own copy of the framework, and its own Composer, so you can build a site on a machine with no PHP and no Composer installed. Point it at a directory of Markdown files and it will build a site; point it at a full HydePHP Composer project and it will run that project through its own dependencies.
The runtime it carries is not kept to itself: hyde php and hyde composer hand it to you.
The two kinds of project
Portable — content and configuration only:
_pages/
_posts/
_media/
hyde.yml # optional
No composer.json, no vendor/, nothing to install. The framework, the runtime, and every
dependency come from the executable itself. Fastest builds and easiest deployment.
Composer — a full HydePHP project with a composer.json that declares Hyde. The project
owns its dependency graph: its own Hyde version and its own addons. The executable supplies
the PHP runtime and hands control to the project's own hyde entry point.
The CLI works out which one it is looking at before it does anything else. hyde info will
tell you what it decided:
$ hyde info
Hyde CLI: 3.0.0
Project type: Portable
Framework: 3.0.0-dev (embedded)
PHP: 8.4.24 (bundled)
Root: /Users/emma/Sites/foo
See docs/ARCHITECTURE.md for the full model.
Installation
Direct download
Download the executable for your platform from the latest release:
| Platform | Asset |
|---|---|
| Linux (x86_64) | hyde-linux-x86_64 |
| Linux (arm64) | hyde-linux-arm64 |
| macOS (Apple Silicon) | hyde-macos-arm64 |
| macOS (Intel) | hyde-macos-x86_64 |
| Windows (x86_64) | hyde-windows-x86_64.exe |
# macOS, Apple Silicon curl -L https://github.com/hydephp/cli/releases/latest/download/hyde-macos-arm64 -o hyde chmod +x hyde && sudo mv hyde /usr/local/bin/hyde
On macOS, download with
curlrather than through a browser. A browser marks the file as quarantined, and Gatekeeper will refuse to run it until you clear that withxattr -d com.apple.quarantine hyde.
Every asset is published with a detached GPG signature (<asset>.sig) and an OpenSSL
signature (<asset>.sig.bin), which is the one hyde self-update verifies.
Using Composer 
composer global require hyde/cli
Make sure to place the Composer system-wide vendor bin directory in your $PATH so the hyde executable can be located by your system. This directory is typically located at $HOME/.composer/vendor/bin.
Docker
docker pull ghcr.io/hydephp/cli:latest
docker run --rm -it -v "$(pwd):/site" ghcr.io/hydephp/cli:latest build
The image is a bare Alpine with the Linux executable in it: it needs no PHP layer, because the executable brings its own.
Usage
# List available commands hyde # See what the CLI is, and what it is about to run against hyde info # Create a new site hyde new my-site # asks which kind you want hyde new my-site --portable # content only, nothing to install hyde new my-site --composer # a full Composer project, created with the bundled Composer # Build a site using source files in the working directory hyde build # Preview it, with live recompilation hyde serve
The bundled runtime
The PHP and the Composer inside the executable are available as commands of their own, so a machine that has neither still has both:
hyde php -v # the bundled PHP CLI hyde php script.php hyde php -r 'echo PHP_VERSION;' hyde composer install # the bundled Composer, on the bundled PHP hyde composer require hyde/framework
Arguments and exit statuses pass through untouched. This is Hyde's PHP rather than a general
distribution: its extensions are the ones Hyde needs, listed with their reasons in
build/runtime.json, so a script that needs something outside that set
will say so.
hyde composer is answered before the project is even looked at, which is deliberate: a
Composer project with a missing vendor/ is the one state the CLI refuses to build, and
hyde composer install is what repairs it.
Both commands mean the programs Hyde supplies, so neither falls back to one installed on
the machine. hyde composer self-update is refused for the same reason: the bundled
Composer is versioned with the executable and verified on every run, so hyde self-update
is what gets you a newer one.
Resources
Changelog
Please see CHANGELOG for more information on what has changed recently.
Contributing
HydePHP is an open-source project, contributions are very welcome! See CONTRIBUTING.md for guidance.
Security
If you discover any security-related issues, please email emma@desilva.se instead of using the issue tracker. All vulnerabilities will be promptly addressed.
Credits
- Emma De Silva, feel free to buy me a coffee! https://buymeacoffee.com/emmads
- All Contributors
License
The MIT License. Please see the License File for more information.