Installation
These steps take you from a download to an extension that builds, passes its checks and deploys to Drupal.org. Each step links to the page with the details, so you can follow the list once and come back to the parts you need.
Overview
- Download Eddy: the latest release, or the current code with Code → Download ZIP in the GitHub UI.
- Expand it into a new directory.
- Run the installer there and answer its questions.
- If you already have extension code, copy it into the directory.
- Build the site to check that everything works.
- Check coding standards.
- Run the tests.
- Create your extension's repository on GitHub, then commit and push.
- Configure branch protection.
- Configure deployment to Drupal.org.
Eddy is a GitHub template, so you can also create your repository with Use this template, clone it and run the installer in the clone. The README badges then name your repository on their own. A clone doesn't record the Eddy release it came from, though, so the first update can't tell your changes from the template's, and every difference comes up for a decision.
Running the installer
Run the installer from the root of the new directory:
php install.php
It asks about your extension, renames and rewrites the template's files to match, and removes what you didn't select. It finishes by deleting itself, unless you answer no to "Remove this script".
| Question | What it decides | Default |
|---|---|---|
| Extension name | The human-readable name, such as My Extension. | - |
| Machine name | The machine name, such as my_extension, which files, classes and services are renamed after. | - |
| Extension type | Module or theme. | Module |
| Target Drupal versions | The Drupal majors CI tests: 10, 11 and 12. See Drupal versions. | 11 |
| Command wrapper | Ahoy, Makefile, both or neither. Without a wrapper, you run the tooling commands yourself. | Neither |
| Tools | The tools to keep: PHPCS, PHPStan, Rector, Twig CS Fixer, ESLint, Stylelint, CSpell, Jest, PHPUnit, FunctionalJavascript tests and Renovate. | All 11 |
| Keep example lifecycle scripts | 4 example lifecycle scripts, 1 per phase, that print a marker line when their phase runs. | No |
| Remove this script | Whether install.php deletes itself when it's done. | Yes |
| Proceed with installation | A last check before anything changes. | Yes |
Every answer can come from an environment variable instead, which is handy in scripts and for AI agents. php install.php --help lists them.
What the installer changes
The installer works on the directory in place:
- It renames the
your_extension.*files, classes and tests after your machine name and replaces the placeholders inside them. A theme drops the files only a module uses (.module,.install, the routing, services and menu links files, and the service class) and getsbase theme: falsein its.info.yml. - It removes what you didn't select: the CI jobs and README badges of a Drupal major, a tool with its configuration and CI steps, or a command wrapper with its file. Dropping PHPUnit drops FunctionalJavascript tests too, since they run on PHPUnit.
- It turns
README.dist.mdandCONTRIBUTING.dist.mdinto yourREADME.mdandCONTRIBUTING.md, and downloads a placeholderlogo.pngwith your extension name on it. - It deletes Eddy's own files:
.eddy/,MIGRATION.md,SECURITY.md,LICENSE.txt,logo.svgand theeddy-*workflows. - It sets the branch filters of the workflows to
1.x. Run it again in an existing project and it keeps the branches of the committed.github/workflows/test.ymlinstead. Deployment explains how to build and deploy other branches. - It records the Eddy release you downloaded as
extra.eddy.versionincomposer.dev.json, so a later update knows where your project started.
The README badges name your GitHub repository when you run the installer in a clone of it, and your machine name for both the owner and the name otherwise, so check them before your first commit.
Next steps
With the questions answered, build the site:
- Make
- Ahoy
- No wrapper
make build
ahoy build
scripts/eddy-tooling # Install the tooling
vendor/bin/eddy-assemble # Assemble the codebase
vendor/bin/eddy-start # Start the PHP server
vendor/bin/eddy-provision # Provision the Drupal website
Then work through the rest of the overview: coding standards, tests, the GitHub repository, branch protection and deployment.