diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000000..f4d11f2592 --- /dev/null +++ b/.gitignore @@ -0,0 +1,15 @@ +.csslintrc +.editorconfig +.eslintignore +.eslintrc.json +.gitattributes +.ht.router.php +.htaccess +INSTALL.txt +README.txt +example.gitignore +index.php +robots.txt +update.php +web.config +autoload.php \ No newline at end of file diff --git a/autoload.php b/autoload.php deleted file mode 100644 index 1e5ad34e3b..0000000000 --- a/autoload.php +++ /dev/null @@ -1,14 +0,0 @@ -=7.0.8" + }, + "type": "library", + "extra": { + "composer-scaffold": { + "file-mapping": { + "[web-root]/.csslintrc": "assets/csslintrc", + "[web-root]/.editorconfig": "assets/editorconfig", + "[web-root]/.eslintignore": "assets/eslintignore", + "[web-root]/.eslintrc.json": "assets/eslintrc.json", + "[web-root]/.gitattributes": "assets/gitattributes", + "[web-root]/.ht.router.php": "assets/ht.router.php", + "[web-root]/.htaccess": "assets/htaccess", + "[web-root]/example.gitignore": "assets/example.gitignore", + "[web-root]/index.php": "assets/index.php", + "[web-root]/robots.txt": "assets/robots.txt", + "[web-root]/update.php": "assets/update.php", + "[web-root]/web.config": "assets/web.config", + "[web-root]/sites/default/default.services.yml": "assets/default.services.yml", + "[web-root]/sites/default/default.settings.php": "assets/default.settings.php", + "[web-root]/sites/example.settings.local.php": "assets/example.settings.local.php", + "[web-root]/sites/development.services.yml": "assets/development.services.yml", + "[web-root]/sites/default/settings.php": { + "path": "assets/default.settings.php", + "overwrite": false + }, + "[web-root]/sites/example.sites.php": "assets/example.sites.php", + "[web-root]/modules/README.txt": "assets/modules.README.txt", + "[web-root]/profiles/README.txt": "assets/profiles.README.txt", + "[web-root]/sites/README.txt": "assets/sites.README.txt", + "[web-root]/themes/README.txt": "assets/themes.README.txt", + "[web-root]/INSTALL.txt": "assets/INSTALL.txt", + "[web-root]/README.txt": "assets/README.txt" + } + } + }, + "license": [ + "GPL-2.0-or-later" + ], + "description": "Assets.", + "homepage": "https://www.drupal.org/project/drupal", + "keywords": [ + "drupal" + ], + "transport-options": { + "symlink": true + } + }, { "name": "easyrdf/easyrdf", "version": "0.9.1", @@ -3657,6 +3714,45 @@ ], "time": "2019-05-24T11:44:05+00:00" }, + { + "name": "drupal/core-composer-scaffold2", + "version": "8.8.x-dev", + "dist": { + "type": "path", + "url": "core/lib/Drupal/Component/Scaffold", + "reference": "815a4cfa7305dcca276c04eaf0888cc228674838" + }, + "require": { + "composer-plugin-api": "^1.0.0", + "php": ">=7.0.8" + }, + "require-dev": { + "composer/composer": "^1.8@stable" + }, + "type": "composer-plugin", + "extra": { + "class": "Drupal\\Component\\Scaffold\\Plugin", + "branch-alias": { + "dev-master": "1.0.x-dev" + } + }, + "autoload": { + "psr-4": { + "Drupal\\Component\\Scaffold\\": "" + } + }, + "license": [ + "GPL-2.0-or-later" + ], + "description": "A flexible Composer project scaffold builder.", + "homepage": "https://www.drupal.org/project/drupal", + "keywords": [ + "drupal" + ], + "transport-options": { + "symlink": true + } + }, { "name": "fabpot/goutte", "version": "v3.2.3", @@ -5770,8 +5866,10 @@ "aliases": [], "minimum-stability": "dev", "stability-flags": { + "drupal/core-scaffold-assets": 20, "behat/mink": 20, - "behat/mink-selenium2-driver": 20 + "behat/mink-selenium2-driver": 20, + "composer/composer": 0 }, "prefer-stable": true, "prefer-lowest": false, @@ -5789,7 +5887,8 @@ "ext-spl": "*", "ext-tokenizer": "*", "ext-xml": "*", - "php": ">=7.0.8" + "php": ">=7.0.8", + "composer-plugin-api": "^1.0.0" }, "platform-dev": [] } diff --git a/core/composer.json b/core/composer.json index 4fee977c23..a7490b1d91 100644 --- a/core/composer.json +++ b/core/composer.json @@ -203,6 +203,7 @@ "core/lib/Drupal/Component/Render/composer.json", "core/lib/Drupal/Component/Serialization/composer.json", "core/lib/Drupal/Component/Scaffold/composer.json", + "core/lib/Drupal/Component/ScaffoldAssets/composer.json", "core/lib/Drupal/Component/Transliteration/composer.json", "core/lib/Drupal/Component/Utility/composer.json", "core/lib/Drupal/Component/Uuid/composer.json", @@ -211,6 +212,11 @@ "recurse": false, "replace": false, "merge-extra": false + }, + "composer-scaffold": { + "allowed-packages": [ + "drupal/core-scaffold-assets" + ] } }, "minimum-stability": "dev", diff --git a/core/lib/Drupal/Component/Scaffold/GenerateAutoloadReferenceFile.php b/core/lib/Drupal/Component/Scaffold/GenerateAutoloadReferenceFile.php index 30d2ce1d36..caf8a9f29f 100644 --- a/core/lib/Drupal/Component/Scaffold/GenerateAutoloadReferenceFile.php +++ b/core/lib/Drupal/Component/Scaffold/GenerateAutoloadReferenceFile.php @@ -62,7 +62,7 @@ public static function generateAutoload(IOInterface $io, $package_name, $web_roo */ public static function autoloadFileCommitted(IOInterface $io, $package_name, $web_root) { $autoload_path = static::autoloadPath($package_name, $web_root); - $location = dirname($autoload_path->fullPath()); + $location = $autoload_path->fullPath(); if (!file_exists($location)) { return FALSE; } diff --git a/core/lib/Drupal/Component/Scaffold/Operations/ReplaceOp.php b/core/lib/Drupal/Component/Scaffold/Operations/ReplaceOp.php index 450c448bb6..a9894610e5 100644 --- a/core/lib/Drupal/Component/Scaffold/Operations/ReplaceOp.php +++ b/core/lib/Drupal/Component/Scaffold/Operations/ReplaceOp.php @@ -105,6 +105,7 @@ protected function copyScaffold(ScaffoldFilePath $destination, IOInterface $io) */ protected function symlinkScaffold(ScaffoldFilePath $destination, IOInterface $io) { $interpolator = $destination->getInterpolator(); + $this->source->addInterpolationData($interpolator); try { $fs = new Filesystem(); $fs->relativeSymlink($this->source->fullPath(), $destination->fullPath()); diff --git a/INSTALL.txt b/core/lib/Drupal/Component/ScaffoldAssets/assets/INSTALL.txt similarity index 100% rename from INSTALL.txt rename to core/lib/Drupal/Component/ScaffoldAssets/assets/INSTALL.txt diff --git a/README.txt b/core/lib/Drupal/Component/ScaffoldAssets/assets/README.txt similarity index 100% rename from README.txt rename to core/lib/Drupal/Component/ScaffoldAssets/assets/README.txt diff --git a/.csslintrc b/core/lib/Drupal/Component/ScaffoldAssets/assets/csslintrc similarity index 100% rename from .csslintrc rename to core/lib/Drupal/Component/ScaffoldAssets/assets/csslintrc diff --git a/sites/default/default.services.yml b/core/lib/Drupal/Component/ScaffoldAssets/assets/default.services.yml similarity index 100% rename from sites/default/default.services.yml rename to core/lib/Drupal/Component/ScaffoldAssets/assets/default.services.yml diff --git a/sites/default/default.settings.php b/core/lib/Drupal/Component/ScaffoldAssets/assets/default.settings.php similarity index 100% rename from sites/default/default.settings.php rename to core/lib/Drupal/Component/ScaffoldAssets/assets/default.settings.php diff --git a/sites/development.services.yml b/core/lib/Drupal/Component/ScaffoldAssets/assets/development.services.yml similarity index 100% rename from sites/development.services.yml rename to core/lib/Drupal/Component/ScaffoldAssets/assets/development.services.yml diff --git a/.editorconfig b/core/lib/Drupal/Component/ScaffoldAssets/assets/editorconfig similarity index 100% rename from .editorconfig rename to core/lib/Drupal/Component/ScaffoldAssets/assets/editorconfig diff --git a/.eslintignore b/core/lib/Drupal/Component/ScaffoldAssets/assets/eslintignore similarity index 100% rename from .eslintignore rename to core/lib/Drupal/Component/ScaffoldAssets/assets/eslintignore diff --git a/.eslintrc.json b/core/lib/Drupal/Component/ScaffoldAssets/assets/eslintrc.json similarity index 100% rename from .eslintrc.json rename to core/lib/Drupal/Component/ScaffoldAssets/assets/eslintrc.json diff --git a/example.gitignore b/core/lib/Drupal/Component/ScaffoldAssets/assets/example.gitignore similarity index 100% rename from example.gitignore rename to core/lib/Drupal/Component/ScaffoldAssets/assets/example.gitignore diff --git a/sites/example.settings.local.php b/core/lib/Drupal/Component/ScaffoldAssets/assets/example.settings.local.php similarity index 100% rename from sites/example.settings.local.php rename to core/lib/Drupal/Component/ScaffoldAssets/assets/example.settings.local.php diff --git a/sites/example.sites.php b/core/lib/Drupal/Component/ScaffoldAssets/assets/example.sites.php similarity index 100% rename from sites/example.sites.php rename to core/lib/Drupal/Component/ScaffoldAssets/assets/example.sites.php diff --git a/.gitattributes b/core/lib/Drupal/Component/ScaffoldAssets/assets/gitattributes similarity index 100% rename from .gitattributes rename to core/lib/Drupal/Component/ScaffoldAssets/assets/gitattributes diff --git a/.ht.router.php b/core/lib/Drupal/Component/ScaffoldAssets/assets/ht.router.php similarity index 100% rename from .ht.router.php rename to core/lib/Drupal/Component/ScaffoldAssets/assets/ht.router.php diff --git a/.htaccess b/core/lib/Drupal/Component/ScaffoldAssets/assets/htaccess similarity index 100% rename from .htaccess rename to core/lib/Drupal/Component/ScaffoldAssets/assets/htaccess diff --git a/index.php b/core/lib/Drupal/Component/ScaffoldAssets/assets/index.php similarity index 100% rename from index.php rename to core/lib/Drupal/Component/ScaffoldAssets/assets/index.php diff --git a/modules/README.txt b/core/lib/Drupal/Component/ScaffoldAssets/assets/modules.README.txt similarity index 100% rename from modules/README.txt rename to core/lib/Drupal/Component/ScaffoldAssets/assets/modules.README.txt diff --git a/profiles/README.txt b/core/lib/Drupal/Component/ScaffoldAssets/assets/profiles.README.txt similarity index 100% rename from profiles/README.txt rename to core/lib/Drupal/Component/ScaffoldAssets/assets/profiles.README.txt diff --git a/robots.txt b/core/lib/Drupal/Component/ScaffoldAssets/assets/robots.txt similarity index 100% rename from robots.txt rename to core/lib/Drupal/Component/ScaffoldAssets/assets/robots.txt diff --git a/sites/README.txt b/core/lib/Drupal/Component/ScaffoldAssets/assets/sites.README.txt similarity index 100% rename from sites/README.txt rename to core/lib/Drupal/Component/ScaffoldAssets/assets/sites.README.txt diff --git a/themes/README.txt b/core/lib/Drupal/Component/ScaffoldAssets/assets/themes.README.txt similarity index 100% rename from themes/README.txt rename to core/lib/Drupal/Component/ScaffoldAssets/assets/themes.README.txt diff --git a/update.php b/core/lib/Drupal/Component/ScaffoldAssets/assets/update.php similarity index 100% rename from update.php rename to core/lib/Drupal/Component/ScaffoldAssets/assets/update.php diff --git a/web.config b/core/lib/Drupal/Component/ScaffoldAssets/assets/web.config similarity index 100% rename from web.config rename to core/lib/Drupal/Component/ScaffoldAssets/assets/web.config diff --git a/core/lib/Drupal/Component/ScaffoldAssets/composer.json b/core/lib/Drupal/Component/ScaffoldAssets/composer.json new file mode 100644 index 0000000000..8b1db353d2 --- /dev/null +++ b/core/lib/Drupal/Component/ScaffoldAssets/composer.json @@ -0,0 +1,43 @@ +{ + "name": "drupal/core-scaffold-assets", + "description": "Assets.", + "keywords": ["drupal"], + "homepage": "https://www.drupal.org/project/drupal", + "license": "GPL-2.0-or-later", + "require": { + "php": ">=7.0.8" + }, + "extra": { + "composer-scaffold": { + "file-mapping": { + "[web-root]/.csslintrc": "assets/csslintrc", + "[web-root]/.editorconfig": "assets/editorconfig", + "[web-root]/.eslintignore": "assets/eslintignore", + "[web-root]/.eslintrc.json": "assets/eslintrc.json", + "[web-root]/.gitattributes": "assets/gitattributes", + "[web-root]/.ht.router.php": "assets/ht.router.php", + "[web-root]/.htaccess": "assets/htaccess", + "[web-root]/example.gitignore": "assets/example.gitignore", + "[web-root]/index.php": "assets/index.php", + "[web-root]/robots.txt": "assets/robots.txt", + "[web-root]/update.php": "assets/update.php", + "[web-root]/web.config": "assets/web.config", + "[web-root]/sites/default/default.services.yml": "assets/default.services.yml", + "[web-root]/sites/default/default.settings.php": "assets/default.settings.php", + "[web-root]/sites/example.settings.local.php": "assets/example.settings.local.php", + "[web-root]/sites/development.services.yml": "assets/development.services.yml", + "[web-root]/sites/default/settings.php": { + "path": "assets/default.settings.php", + "overwrite": false + }, + "[web-root]/sites/example.sites.php": "assets/example.sites.php", + "[web-root]/modules/README.txt": "assets/modules.README.txt", + "[web-root]/profiles/README.txt": "assets/profiles.README.txt", + "[web-root]/sites/README.txt": "assets/sites.README.txt", + "[web-root]/themes/README.txt": "assets/themes.README.txt", + "[web-root]/INSTALL.txt": "assets/INSTALL.txt", + "[web-root]/README.txt": "assets/README.txt" + } + } + } +}