Code
Explorer
You are a developer and looking for Shopware projects?
Apply Now!
getVendorPluginPath example
/** @var CompletePackageInterface[] $composerPackages */
$composerPackages
=
$composer
->
getRepositoryManager
(
)
->
getLocalRepository
(
)
->
getPackages
(
)
;
foreach
(
$composerPackages
as
$composerPackage
)
{
if
(
!
$this
->
isShopwarePluginType
(
$composerPackage
)
)
{
continue
;
}
$pluginPath
=
$this
->
getVendorPluginPath
(
$composerPackage
,
$composer
)
;
if
(
!
$this
->
isPluginComposerValid
(
$composerPackage
)
)
{
$this
->
addError
(
$pluginPath
,
$errors
)
;
continue
;
}
$pluginBaseClass
=
$this
->
getPluginNameFromPackage
(
$composerPackage
)
;
$localPlugin
=
$plugins
[
$pluginBaseClass
]
?? null;
$plugins
[
$pluginBaseClass
]
=
(
new
PluginFromFileSystemStruct
(
)
)
->
assign
(
[