generated from alleyinteractive/create-wordpress-plugin
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1,626 changed files
with
122,365 additions
and
162 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,22 @@ | ||
# Build files | ||
build | ||
vendor | ||
composer.lock | ||
node_modules | ||
|
||
# Log files | ||
*.log | ||
|
||
# Cache files | ||
.phpcs/*.json | ||
.phpunit.result.cache | ||
|
||
# Ignore temporary OS files | ||
.DS_Store | ||
.DS_Store? | ||
.Spotlight-V100 | ||
.Trashes | ||
ehthumbs.db | ||
Thumbs.db | ||
.thumbsdb | ||
|
||
# IDE files | ||
*.code-workspace | ||
.idea | ||
.vscode | ||
wp-cli.local.yml | ||
node_modules/ | ||
*.sql | ||
*.tar.gz | ||
*.zip | ||
.phpunit.result.cache | ||
Dockerfile | ||
output.log | ||
.github | ||
tests | ||
bin | ||
composer.lock | ||
phpcs.xml | ||
phpunit.xml | ||
configure.php | ||
DOCKER_ENV | ||
phpunit.xml | ||
tests | ||
.phpcs | ||
Makefile |
47 changes: 47 additions & 0 deletions
47
vendor/alleyinteractive/composer-wordpress-autoloader/CHANGELOG.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
# Changelog | ||
|
||
All notable changes to `alleyinteractive/composer-wordpress-autoloader` will be | ||
documented in this file. | ||
|
||
## Unreleased | ||
|
||
## v0.8.0 | ||
|
||
- Automatically translate the `vendor-dir` and set the autoloaded files relative to the root directory of the project. | ||
|
||
## v0.7.0 | ||
|
||
- Add APCu autoloader. | ||
- Bump `alleyinteractive/wordpress-autoloader` to `v1.1.0`. | ||
|
||
## v0.6.0 | ||
|
||
- Simplify injection of autoloader. | ||
- Automatically load the autoloader inside of `vendor/autoload.php` without the | ||
need to load `vendor/wordpress-autoload.php` manually. | ||
|
||
## v0.4.1 | ||
|
||
### Updated | ||
|
||
* Fix Composer Injection to `vendor/autoload.php` in https://github.com/alleyinteractive/composer-wordpress-autoloader/pull/10 | ||
|
||
## v0.4.0 | ||
|
||
### Added | ||
|
||
- Bump alleyinteractive/wordpress-autoloader to 0.2 by @srtfisher in https://github.com/alleyinteractive/composer-wordpress-autoloader/pull/7 | ||
- Supports PHP 8.1 | ||
|
||
## 0.3.0 | ||
|
||
- Remove specific Composer version dependency. | ||
|
||
## 0.2.0 | ||
|
||
- Updates autoloader to use non-hard-coded paths. | ||
- Adds support for dependencies to autoload files as well, fixes [#3](https://github.com/alleyinteractive/composer-wordpress-autoloader/issues/3). | ||
|
||
## 0.1.0 | ||
|
||
- Initial release. |
94 changes: 94 additions & 0 deletions
94
vendor/alleyinteractive/composer-wordpress-autoloader/README.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,94 @@ | ||
# Composer WordPress Autoloader | ||
|
||
[](https://packagist.org/packages/alleyinteractive/composer-wordpress-autoloader) | ||
[](https://github.com/alleyinteractive/composer-wordpress-autoloader/actions/workflows/tests.yml) | ||
|
||
Autoload WordPress files configured via Composer that support the [Wordpress | ||
Coding | ||
Standards](https://developer.wordpress.org/coding-standards/wordpress-coding-standards/php/) | ||
using | ||
[alleyinteractive/wordpress-autoloader](https://github.com/alleyinteractive/wordpress-autoloader). | ||
Will load the autoloaded classes defined in your package and all autoloaded | ||
classes in your dependencies. | ||
|
||
## Installation | ||
|
||
You can install the package via composer: | ||
|
||
```bash | ||
composer require alleyinteractive/composer-wordpress-autoloader | ||
``` | ||
|
||
## Usage | ||
|
||
```json | ||
{ | ||
"autoload": { | ||
"wordpress": { | ||
"My_Plugin_Namespace\\": "src/", | ||
} | ||
}, | ||
"autoload-dev": { | ||
"wordpress": { | ||
"My_Plugin_Namespace\\Tests\\": "tests/", | ||
} | ||
} | ||
} | ||
``` | ||
|
||
Once added, you can load `vendor/autoload.php` as normal and the autoloader will | ||
handle the rest. If that doesn't work, see [Automatically Injecting WordPress | ||
Autoloader](#automatically-injecting-wordpress-autoloader). | ||
|
||
### Use Inside Packages Published to Packagist | ||
|
||
Packages published to Packagist are required to be valid and have a | ||
`composer.json` that passed a `composer validate`. Composer does not consider | ||
`wordpress` to be a valid value inside of the `autoload` or `autoload-dev` | ||
property. To allow packages to register autoloading in a valid format, you can | ||
use the following format: | ||
|
||
```json | ||
{ | ||
"extra": { | ||
"wordpress-autoloader": { | ||
"autoload": { | ||
"My_Plugin_Namespace\\": "src/", | ||
}, | ||
"autoload-dev": { | ||
"My_Plugin_Namespace\\Tests\\": "tests/", | ||
} | ||
} | ||
} | ||
} | ||
``` | ||
|
||
### Automatically Injecting WordPress Autoloader | ||
|
||
By default Composer WordPress Autoloader will automatically load the WordPress | ||
autoloader. This is done by adding `src/autoload.php` as an autoloaded file to | ||
Composer. However, this may not always work under some circumstances including | ||
symlinks. When necessary, you can opt to inject the | ||
`vendor/wordpress-autoload.php` file into your `vendor/autoload.php` file. This | ||
is disabled by default and be enabled by setting `inject` to `true` in your | ||
`composer.json`. | ||
|
||
```json | ||
{ | ||
"extra": { | ||
"wordpress-autoloader": { | ||
"inject": true | ||
} | ||
} | ||
} | ||
``` | ||
|
||
## Testing | ||
|
||
```bash | ||
composer test | ||
``` | ||
|
||
## Changelog | ||
|
||
Please see [CHANGELOG](CHANGELOG.md) for more information on what has changed recently. |
55 changes: 55 additions & 0 deletions
55
vendor/alleyinteractive/composer-wordpress-autoloader/composer.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
{ | ||
"name": "alleyinteractive/composer-wordpress-autoloader", | ||
"type": "composer-plugin", | ||
"description": "Autoload files using WordPress File Conventions using Composer", | ||
"license": "GPL-2.0-or-later", | ||
"authors": [ | ||
{ | ||
"name": "Alley Interactive", | ||
"email": "[email protected]" | ||
}, | ||
{ | ||
"name": "Sean Fisher", | ||
"email": "[email protected]" | ||
} | ||
], | ||
"require": { | ||
"php": "^7.4.0|^8.0|^8.1", | ||
"alleyinteractive/wordpress-autoloader": "^1.1.1", | ||
"composer-plugin-api": "^2.0" | ||
}, | ||
"require-dev": { | ||
"composer/composer": "*", | ||
"phpunit/phpunit": "^9.5.8", | ||
"squizlabs/php_codesniffer": "^4.0" | ||
}, | ||
"extra": { | ||
"class": "ComposerWordPressAutoloader\\Plugin" | ||
}, | ||
"autoload": { | ||
"files": [ | ||
"src/autoload.php" | ||
], | ||
"psr-4": { | ||
"ComposerWordPressAutoloader\\": "src/" | ||
} | ||
}, | ||
"minimum-stability": "dev", | ||
"prefer-stable": true, | ||
"scripts": { | ||
"lint": "@phpcs", | ||
"lint:fix": "@phpcbf", | ||
"phpcbf": "phpcbf --standard=./phpcs.xml.dist .", | ||
"phpcs": "phpcs --standard=./phpcs.xml.dist .", | ||
"phpunit": "phpunit", | ||
"test": [ | ||
"@phpcs", | ||
"@phpunit" | ||
] | ||
}, | ||
"config": { | ||
"allow-plugins": { | ||
"dealerdirect/phpcodesniffer-composer-installer": true | ||
} | ||
} | ||
} |
Oops, something went wrong.