Scopes are defined in the Scopes dialog box in the following modes:
Manually, by specifying file masks in the Pattern text box. The following elements and structures are used:
- The file: modifier. The element is mandatory.
- The * asterisk to denote any symbol in a file name or file extension.
- Logical operators AND (&&), OR (||), and NOT (!).
- By selecting files and folders and clicking the buttons Include, Include Recursively, Exclude, and Exclude Recursively. Based on the inclusion/exclusion, PhpStorm creates an expression and displays it in the Pattern.
- file:*.php||file:*.twig - include all PHP and Twig files.
- file^*php&&!file:*test*.php - include all PHP files except those that contain the character string test in their names.
- file:www/wp-content/themes/my-site-child//*.php||file:www/wp-content/themes/my-site-child//*.css||file:www/wp-content/themes/my-site-child//*.js||file:www/wp-content/plugins/my-site//*.php||file:www/wp-content/plugins/my-site//*.css||file:www/wp-content/plugins/my-site//*.js - include all .PHP, .CSS, and .JS files from the theme and plugin of the WordPress website.