guyiday / guyiday-drupal-distribution

此包最新版本(v1.0.0)没有可用的许可证信息。

爆裂Drupal发行版。仅供内部使用。

v1.0.0 2024-01-02 08:28 UTC

This package is not auto-updated.

Last update: 2024-09-26 15:57:06 UTC


README

因为我们大量使用Drupal 9,这使得我们所有人都更容易。

这个发行版的目标是减少我们项目中的样板代码量。减少项目之间的复制粘贴,更多地重用相同的代码。

如何使用

创建一个 composer.json 文件,并确保它至少包含以下内容

{
  "type": "project",
  "minimum-stability": "dev",
  "prefer-stable": true,
  "repositories": [
    {
      "type": "composer",
      "url": "https://packages.drupal.org/8"
    }
  ],
  "require": {},
  "extra": {
    "installer-paths": {
      "web/core": [
        "type:drupal-core"
      ],
      "web/libraries/{$name}": [
        "type:drupal-library"
      ],
      "web/modules/contrib/{$name}": [
        "type:drupal-module"
      ],
      "web/profiles/contrib/{$vendor}-{$name}": [
        "type:drupal-profile"
      ],
      "web/themes/contrib/{$name}": [
        "type:drupal-theme"
      ],
      "drush/contrib/{$name}": [
        "type:drupal-drush"
      ]
    },
    "enable-patching": true,
    "drupal-scaffold": {
      "locations": {
        "web-root": "web"
      }
    },
    "composer-exit-on-patch-failure": true
  },
  "config": {
    "sort-packages": true,
    "discard-changes": true,
    "platform": {
      "php": "7.4.999",
      "ext-curl": "7.4.999",
      "ext-gd": "7.4.999"
    }
  }
}

注意以下内容

  • 不需要 drupal/core,它已经由 Burst 发行版要求。

然后,运行 composer require burst/drupal-distribution

现在,所有步骤中最关键的一步.. 将 /web/sites/default/settings.php 替换为以下内容

<?php

// This also includes settings.local.php and settings.ddev.php if these files exist.
require __DIR__ . '/../../profiles/contrib/burst-drupal-distribution/includes/settings.php';

砰!这包括Platform.sh、Lando以及未来可能的其他服务所需的所有配置。