View Issue Details

IDProjectCategoryView StatusLast Update
0006793OXID eShop (all versions)6. ------ Setup -------public2019-04-18 12:11
Reporterusenff Assigned To 
Status resolvedResolutionfixed 
Product Version6.0.1 
Fixed in Version6.1.4 
Summary0006793: Setup folder is copied on every "composer update" although Setup was already executed
DescriptionIf you run "composer update" and answer the question "Do you want to overwrite existing OXID eShop files? (y/N) " with "y" the folder "Setup" will always be copied to "source" even if the Setup was already executed before.
Steps To Reproduce- Setup an oxid-shop via composer
- execute the setup
- confirm that the "Setup"-folder was removed from "source"
- run "composer update"
- answer "Do you want to overwrite existing OXID eShop files? (y/N)" with "y"
Additional InformationThere are two mechanisms that should prevent that the "Setup"-folder is copied every time "composer update" is run.

1. don't copy Setup files @ OxidEsales\ComposerPlugin\Installer\Package\ShopPackageInstaller::copySetupFiles if "" is configured
- I can confirm, that this check works as designed

2. never copy Setup files @ OxidEsales\ComposerPlugin\Installer\Package\ShopPackageInstaller::copyShopSourceFromPackageToTarget
- The files should be excluded via filter "self::SETUP_FILES_FILTER"
- The filter currently used is "Setup**/*" which doesn't work because of a missing "/"
- In my opinion the filter should be "Setup/**/*"
TagsSolution Provided
ThemeNot defined
BrowserNot defined
PHP VersionNot defined
Database VersionNot defined



2018-02-21 14:18

administrator   ~0012393

The described filter self::SETUP_FILES_FILTER is built with self::SHOP_SOURCE_SETUP_DIRECTORY and AbstractPackageInstaller::BLACKLIST_ALL_FILES. The second one is implemented in the following way:

/** Glob expression to filter all files, might be used to filter whole directory. */
    const BLACKLIST_ALL_FILES = '**/*';

First comment phrase is correct. 'All files' will be filtered, but not the directories. So /Setup is always copied together within /Setup/Controller etc.
As mentioned from usenff, the glob expression '/**/*' would filter everything in /Setup including the directory itself (succesfully tested).


2019-02-18 16:17

administrator   ~0012784

Hello, PR-13 fixes the problem. Merged to master.


2019-02-18 16:37

administrator   ~0012785

Will be ported to b-2.x as well, so will be available in next 6.1 patch.