Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 265c3b1

Browse files
Use new Drupal Finder API. (#673)
1 parent 201e219 commit 265c3b1

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

‎composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
"drush/drush": "^12.4.3",
1818
"oomphinc/composer-installers-extender": "^2.0",
1919
"vlucas/phpdotenv": "^5.1",
20-
"webflo/drupal-finder": "^1.2"
20+
"webflo/drupal-finder": "^1.3"
2121
},
2222
"require-dev": {
2323
"drupal/core-dev": "^10.2.0",

‎scripts/composer/ScriptHandler.php

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,15 +12,14 @@
1212
use Drupal\Core\Site\Settings;
1313
use Drupal\Core\Site\SettingsEditor;
1414
use DrupalFinder\DrupalFinder;
15+
use DrupalFinder\DrupalFinderComposerRuntime;
1516
use Symfony\Component\Filesystem\Filesystem;
16-
use Symfony\Component\Filesystem\Path;
1717

1818
class ScriptHandler {
1919

2020
public static function createRequiredFiles(Event $event) {
2121
$fs = new Filesystem();
22-
$drupalFinder = new DrupalFinder();
23-
$drupalFinder->locateRoot(getcwd());
22+
$drupalFinder = new DrupalFinderComposerRuntime();
2423
$drupalRoot = $drupalFinder->getDrupalRoot();
2524

2625
$dirs = [
@@ -44,7 +43,7 @@ public static function createRequiredFiles(Event $event) {
4443
require_once $drupalRoot . '/core/includes/install.inc';
4544
new Settings([]);
4645
$settings['settings']['config_sync_directory'] = (object) [
47-
'value' => Path::makeRelative($drupalFinder->getComposerRoot() . '/config/sync', $drupalRoot),
46+
'value' => '../config/sync',
4847
'required' => TRUE,
4948
];
5049
SettingsEditor::rewrite($drupalRoot . '/sites/default/settings.php', $settings);

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /