Skip to content

Commit d4ba632

Browse files
authored
[docs] DDEV project type (#7)
* remove EOL whitespace * add blank line after heading * Add a troubleshooting section --------- Co-authored-by: tyler36 <7234392+tyler36@users.noreply.github.com>
1 parent 55329cb commit d4ba632

File tree

1 file changed

+20
-5
lines changed

1 file changed

+20
-5
lines changed

README.md

Lines changed: 20 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,18 +2,20 @@ DDEV integration for developing Drupal contrib projects. As a general philosophy
22

33
Install
44
===========
5+
56
1. `git clone` your contrib module
67
2. [Add DDEV to your contrib project](https://ddev.readthedocs.io/en/latest/users/project/) if not already added.
78
3. Run `ddev get ddev/ddev-drupal-contrib`.
89

910
Commands
1011
============
12+
1113
This project provides the following DDEV container commands.
1214

13-
- [ddev poser](https://github.com/ddev/ddev-drupal-contrib/blob/main/commands/web/poser).
14-
- Edits composer.json so that `drupal/core-recommended` becomes a dev dependency.
15-
- Runs `composer install` AND `yarn install` so that dependencies are available.
16-
- Note: it is perfectly acceptable to skip this command and edit the require-dev of composer.json by hand.
15+
- [ddev poser](https://github.com/ddev/ddev-drupal-contrib/blob/main/commands/web/poser).
16+
- Edits composer.json so that `drupal/core-recommended` becomes a dev dependency.
17+
- Runs `composer install` AND `yarn install` so that dependencies are available.
18+
- Note: it is perfectly acceptable to skip this command and edit the require-dev of composer.json by hand.
1719
- [ddev symlink-project](https://github.com/ddev/ddev-drupal-contrib/blob/main/commands/web/symlink-project). This symlinks the top level files of your project into web/modules/custom so that Drupal finds your module. This command runs automatically on every `ddev start`. See codebase image below.
1820
- `ddev phpunit`. Run phpunit tests on the web/modules/custom directory.
1921
- `ddev nightwatch`. Run nightwatch tests on the web/modules/custom directory.
@@ -28,12 +30,25 @@ Codebase layout
2830

2931
Misc
3032
=======
33+
3134
- Optional: [Install Chrome service for FunctionalJavascript and Nightwatch tests](https://github.com/ddev/ddev-selenium-standalone-chrome).
3235
- Optional. Commit the changes .ddev after this plugin installs. This saves other users from having to install this integration. Rerun the `ddev get` in order to update the commands from this project.
3336
- This project reads your `project_type` from DDEV and fetches adds the corresponding version of `drupal/core-recommended` to composer.json. if you are doing something non-standard with project_type, don't use `ddev poser` command.
3437
- This project should work for any contrib project, including those that haven't [opted into Gitlab CI](https://www.drupal.org/project/infrastructure/issues/3261803). One advantage of that is that failures in CI are more likely to be reproducible locally when using this integration.
35-
- If you add/remove a root file or directory, re-symlink root files via EITHER of these methods
38+
- If you add/remove a root file or directory, re-symlink root files via EITHER of these methods
3639
- `ddev restart`
3740
- `ddev symlink-project`
3841

42+
Troubleshooting
43+
=======
44+
45+
"Error: unknown command":
46+
47+
The commands from this addon are available when the project type a valid `drupal` type.
48+
Below, is an example `.ddev/config.yaml` for a Drupal 10 project.
49+
50+
```yaml
51+
type: drupal10
52+
```
53+
3954
**Contributed and maintained by [@weitzman](https://github.com/weitzman)**

0 commit comments

Comments
 (0)