You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat: use DRUPAL_PROJECTS_PATH for all commands. fixes#111 (#112)
* feat: use DRUPAL_PROJECTS_PATH for all commands
* refactor: centralize DRUPAL_PROJECTS_PATH in config
- Move DRUPAL_PROJECTS_PATH to config.contrib.yaml
- Remove individual definitions from command files
- Improve documentation for theme support
* docs: clarify configurable project location in commands section
Link to configuration section and note default location.
* docs: align symlink location documentation
Make messaging consistent about configurable project location
throughout README and command description
* docs: align README references in config.contrib.yaml
Copy file name to clipboardExpand all lines: README.md
+8-4Lines changed: 8 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -40,15 +40,15 @@ This project provides the following DDEV container commands.
40
40
- Creates a temporary [composer.contrib.json](https://getcomposer.org/doc/03-cli.md#composer) so that `drupal/core-recommended` becomes a dev dependency. This way the composer.json from the module is untouched.
41
41
- Runs `composer install` AND `yarn install` so that dependencies are available. Additional arguments to `ddev poser` like --prefer-source are passed along to `composer install`
42
42
- Note: it is perfectly acceptable to skip this command and edit the require-dev of composer.json by hand.
43
-
-[ddev symlink-project](https://github.com/ddev/ddev-drupal-contrib/blob/main/commands/web/symlink-project). 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`_as long as Composer has generated `vendor/autoload.php`_ which occurs during `composer install/update`. See codebase image below.
43
+
-[ddev symlink-project](https://github.com/ddev/ddev-drupal-contrib/blob/main/commands/web/symlink-project). Symlinks your project files into the configured location (defaults to `web/modules/custom`) so Drupal can find your module. This command runs automatically on every `ddev start`_as long as Composer has generated `vendor/autoload.php`_ which occurs during `composer install/update`. See codebase image below.
44
44
45
-
Run tests on the `web/modules/custom` directory:
45
+
Run tests on your project code (defaults to `web/modules/custom`, [configurable](#changing-the-symlink-location)):
46
46
47
47
-`ddev phpunit` Run [PHPUnit](https://github.com/sebastianbergmann/phpunit) tests.
48
48
-`ddev nightwatch` Run Nightwatch tests, requires [DDEV Selenium Standalone Chrome](https://github.com/ddev/ddev-selenium-standalone-chrome).
49
49
-`ddev phpcs` Run [PHP_CodeSniffer](https://github.com/PHPCSStandards/PHP_CodeSniffer).
50
50
-`ddev phpcbf` Fix phpcs findings.
51
-
-`ddev phpstan`. Run [phpstan](https://phpstan.org) on the web/modules/custom directory.
51
+
-`ddev phpstan`. Run [phpstan](https://phpstan.org) on project files.
52
52
-`ddev eslint` Run [ESLint](https://github.com/eslint/eslint) on JavaScript files.
53
53
-`ddev stylelint` Run [Stylelint](https://github.com/stylelint/stylelint) on CSS files.
54
54
@@ -96,7 +96,11 @@ web_environment:
96
96
- DRUPAL_PROJECTS_PATH=modules
97
97
```
98
98
99
-
Then restart DDEV by running `ddev restart`.
99
+
Then run `ddev restart` to update the symlink location.
100
+
101
+
All [ddev-drupal-contrib commands](#commands) run against your project code in the configured symlink location.
102
+
103
+
To use with Drupal themes, set `DRUPAL_PROJECTS_PATH=themes/custom` in your config.
0 commit comments