Skip to content

Commit 6464f2f

Browse files
authored
Fix #154. symlink-project error after a gitlab_templates release (#155)
* Quick fix for symlink command. The dash-to-undercore handling is removed for now. * README tweak * Set DRUPAL_PROJECT_FOLDER
1 parent 7432399 commit 6464f2f

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ This project provides the following DDEV container commands.
6161

6262
- Optional. The [ddev-selenium-standalone-chrome add-on helps run FunctionalJavascript and Nightwatch tests](https://github.com/ddev/ddev-selenium-standalone-chrome).
6363
- Optional: [Install the ddev-mkdocs extension for local preview of your docs site](https://github.com/nireneko/ddev-mkdocs). Drupal.org's Gitlab CI can [automatically publish your site](https://project.pages.drupalcode.org/gitlab_templates/jobs/pages/).
64-
- Optional. Commit the changes in the `.ddev` folder after this plugin installs. This saves other users from having to install this integration.
64+
- Optional. Commit the changes in the `.ddev` folder after this add-on installs. This saves other users from having to install this integration.
6565
- To install javascript dependencies, run `ddev exec "cd web/core && yarn install"`
6666
- If you add/remove a root file or directory, re-symlink root files via EITHER of these methods
6767
- `ddev restart`

commands/web/symlink-project

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,14 +10,15 @@
1010
set -eu -o pipefail
1111

1212
export _WEB_ROOT=$DDEV_DOCROOT
13-
#todo use more dynamic ref.
1413
cd "$DDEV_COMPOSER_ROOT" || exit
1514
curl -OL https://git.drupalcode.org/project/gitlab_templates/-/raw/default-ref/scripts/symlink_project.php
1615

1716
# Suppress a warning.
1817
PROJECT_FILES=$(ls -A --ignore="web" --ignore="vendor" --ignore="symlink_project.php" --ignore=".ddev" --ignore=".idea")
1918
export PROJECT_FILES
19+
# Used by the symlink-project script in gitlab_templates
2020
# Symlink name using underscores.
2121
# @see https://www.drupal.org/docs/develop/creating-modules/naming-and-placing-your-drupal-module
22-
php symlink_project.php "${DDEV_SITENAME//-/_}"
22+
export DRUPAL_PROJECT_FOLDER=${DDEV_DOCROOT}/${DRUPAL_PROJECTS_PATH}/${DDEV_SITENAME//-/_}
23+
php symlink_project.php
2324
rm -f symlink_project.php

0 commit comments

Comments
 (0)