Setting up a development environment
This page is for application creators setting up a machine to build on Exponential. The goal: a local installation you can reinstall in minutes, with debugging on and your extension in its own Git repository.
Contents
Tools
| Tool | Version |
|---|---|
| PHP | 8.0 or newer, for the kernel and for Velocity (from its release 0.0.4.54), with the extensions of 2.3 |
| Composer | 2.x |
| Git | any current version (Develop with Git) |
| A database | SQLite needs nothing; use the engine of production for integration tests |
A local installation
git clone https://github.com/se7enxweb/exponential.git exp-dev
cd exp-dev
composer install
php bin/php/console exp:install --apply --package=sevenx_multisite_clean --url=http://127.0.0.1:8088SQLite, generated administrator password shown once (The console install).
Reinstalling with the same command (--force) gives a clean state in minutes.
Serving it
composer require se7enxweb/exponential-velocity
php bin/php/console exp:velocity config set --apply ServerSettings Engine qbix
php bin/php/console exp:velocity startVelocity keeps classes in memory: after you add or change a PHP class, exp:velocity restart (or
exp:velocity deploy). For quick template work, --engine=php (PHP's built-in server) runs each request fresh
(8.3 Velocity).
Development settings
In settings/override/site.ini.append.php of the development machine only:
[TemplateSettings]
DevelopmentMode=enabled
ShowTemplatePathComments=enabled
[DebugSettings]
DebugOutput=enabledDevelopmentMode makes compiled templates follow their sources and turns the packer off. The debug bar shows queries,
templates, settings and timings (Exp debug bar,
Debugging and logs). Never copy these settings to production.
Your extension in Git
Keep the application in its own repository, checked out (or symlinked) into extension/<ext>, with its own
composer.json so it installs like any extension later (Composer packages and Packagist).
Activate it in settings/override/site.ini.append.php:
[ExtensionSettings]
ActiveExtensions[]=expdemoDaily commands
php bin/php/ezpgenerateautoloads.php -e # after adding or renaming a class
php bin/php/ezcache.php --clear-tag=ini --allow-root-user # after a settings change
php bin/php/eztemplatecheck.php -s<siteaccess> <file.tpl> # template syntax
php -l <file.php> # PHP syntax
php bin/php/console exp:velocity deploy # everything, in the right orderRelated pages
- Your first extension
- Develop with Git
- PHP and Composer standards
- Free documentation: this page is free to copy, translate and improve under the GNU FDL 1.3.
Become an Exponential Partner
Partners share their information, provide funding, contribute back and develop the products with us, and that is how Exponential grows. A partner website and dashboard are planned for mid-2027: please become a partner today to speed up our growth rate and land new features faster.