-
-
Notifications
You must be signed in to change notification settings - Fork 10
/
finder.php
103 lines (102 loc) · 3.3 KB
/
finder.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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
<?php
return \StubsGenerator\Finder::create()
->in('source/woocommerce/includes')
->append(
\StubsGenerator\Finder::create()
->in(['source/woocommerce'])
->files()
->depth('< 1')
->path('woocommerce.php')
)
->append(
\StubsGenerator\Finder::create()
->in(['source/woocommerce/src'])
->notPath('Internal')
// Uses woocommerce/blueprint
->notPath('Admin/Features/Blueprint')
->sortByName(true)
)
// WC_Query uses this internal trait
->append(
\StubsGenerator\Finder::create()
->in(['source/woocommerce/src/Internal/Traits'])
->files()
->depth('< 1')
->path('AccessiblePrivateMethods.php')
)
// WC_Abstract_Order uses these internal traits
->append(
\StubsGenerator\Finder::create()
->in(['source/woocommerce/src/Internal/CostOfGoodsSold'])
->files()
->depth('< 1')
)
->append(
\StubsGenerator\Finder::create()
->in(['source/woocommerce/src/Internal'])
->files()
->depth('< 1')
->path('RegisterHooksInterface.php')
)
->append(
\StubsGenerator\Finder::create()
->in(['source/woocommerce/src/Internal/Admin/BlockTemplates'])
->files()
->depth('< 1')
//->path('AbstractBlockTemplate.php')
)
->append(
\StubsGenerator\Finder::create()
->in(['source/woocommerce/src/Internal/Traits'])
->files()
->depth('< 1')
->path('OrderAttributionMeta.php')
)
->append(
\StubsGenerator\Finder::create()
->in(['source/woocommerce/lib/packages/Detection'])
->files()
->depth('< 1')
->path('MobileDetect.php')
)
/*
->append(
\StubsGenerator\Finder::create()
->in(['source/woocommerce/src/Internal/Admin'])
->files()
->depth('< 1')
->path('CouponsMovedTrait.php')
)
*/
/*
// Comment out existing interface exclusion
// $ editor vendor/php-stubs/generator/src/NodeVisitor.php:352
->append(
\StubsGenerator\Finder::create()
->in(['source/woocommerce/vendor/psr/container/src'])
->sortByName(true)
)
*/
// Exclude woocommerce.com API as is uses the woocommerce-rest-api package.
->notPath('wccom-site/rest-api/endpoints')
// Exclude WP-CLI command as is extends Plugin_Command.
->notPath('cli/class-wc-cli-com-extension-command.php')
// Templates.
->notPath('admin/views')
->notPath('admin/helper/views')
->notPath('admin/importers/views')
->notPath('admin/marketplace-suggestions/templates')
->notPath('admin/marketplace-suggestions/views')
->notPath('admin/meta-boxes/views')
->notPath('admin/plugin-updates/views')
->notPath('admin/settings/views')
// $ ls includes/shipping/*/includes/*.php
->notPath('shipping/flat-rate/includes/settings-flat-rate.php')
->notPath('shipping/legacy-flat-rate/includes/settings-flat-rate.php')
// Legacy WooCommerce API.
->notPath('api/legacy')
->notPath('legacy/api')
// Update functions.
->notPath('wc-update-functions.php')
->sortByName(true)
;