Code
Explorer
You are a developer and looking for Shopware projects?
Apply Now!
getPluginPaths example
->
in
(
__DIR__ . '/../../*/Resources/app/administration/src/'
)
->
exclude
(
'node_modules'
)
->
ignoreUnreadableDirs
(
)
;
if
(
$locale
)
{
$finder
->
name
(
sprintf
(
'%s.json',
$locale
)
)
;
}
else
{
$finder
->
name
(
'/[a-z]{2}-[A-Z]{2}\.json/'
)
;
}
if
(
$withPlugins
)
{
$finder
->
in
(
$this
->
getPluginPaths
(
)
)
;
}
$iterator
=
$finder
->
getIterator
(
)
;
$files
=
[
]
;
foreach
(
$iterator
as
$file
)
{
$files
[
]
=
$file
->
getRealPath
(
)
;
}
return
\
array_unique
(
$files
)
;
}