forked from box-project/box
-
Notifications
You must be signed in to change notification settings - Fork 0
/
scoper.inc.php
50 lines (44 loc) · 1.26 KB
/
scoper.inc.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
<?php
declare(strict_types=1);
/*
* This file is part of the box project.
*
* (c) Kevin Herrera <[email protected]>
* Théo Fidry <[email protected]>
*
* This source file is subject to the MIT license that is bundled
* with this source code in the file LICENSE.
*/
use Isolated\Symfony\Component\Finder\Finder as IsolatedFinder;
$polyfillFiles = require __DIR__.'/res/scoper-polyfills.php';
$jetBrainStubFiles = require __DIR__.'/res/scoper-phpstorm-stubs.php';
$jetBrainStubPatcher = require __DIR__.'/res/scoper-phpstorm-stubs-map-patcher.php';
return [
'exclude-files' => [
...$polyfillFiles,
...$jetBrainStubFiles,
],
'exclude-namespaces' => [
'Symfony\Polyfill'
],
'exclude-classes' => [
IsolatedFinder::class,
],
'exclude-constants' => [
// Symfony global constants
'/^SYMFONY\_[\p{L}_]+$/',
],
'expose-functions' => [
'trigger_deprecation',
],
'expose-classes' => [
\Composer\Autoload\ClassLoader::class,
\KevinGH\Box\Compactor\Compactor::class,
\KevinGH\Box\Compactor\Json::class,
\KevinGH\Box\Compactor\Php::class,
\KevinGH\Box\Compactor\PhpScoper::class,
],
'patchers' => [
$jetBrainStubPatcher,
]
];