You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Adding a composer.json template would encourage developers to make their plugins available via Packagist, and also allow local install of dependencies.
Currently, WPCS + PHPCS is made available via a global composer install here for Travis.
I haven't yet found a template for the plugin's composer.json, but adding WPCS + PHPCS + PHPCompatibility + DealerDirect/phpcodesniffer-composer-installer to a composer.json would make PHPCS runnable from local, without Travis.
The text was updated successfully, but these errors were encountered:
I can't think of any issues with adding a composer.json for wp scaffold plugin.
However, the original reason for installing WPCS as a global install was to avoid overwriting an existing composer.json in wp scaffold plugin-tests. As such, an implementation for wp scaffold plugin-tests that wanted to create a composer.json would also need to programmatically modify an existing composer.json.
I was thinking about this and I agree that editing an existing composer file is a potential issue. However, that could be a potential issue regardless. Someone might have an existing project they want to add tests to.
So I thought instead of reinventing the wheel in order to update the composer.json file, can/should the wp scaffold plugin file check to see if the composer file exists and if it does use shell_exec() or something similar to run the composer commands to add the packages to the project?
Adding a
composer.json
template would encourage developers to make their plugins available via Packagist, and also allow local install of dependencies.Currently, WPCS + PHPCS is made available via a global composer install here for Travis.
I haven't yet found a template for the plugin's
composer.json
, but adding WPCS + PHPCS + PHPCompatibility +DealerDirect/phpcodesniffer-composer-installer
to acomposer.json
would make PHPCS runnable from local, without Travis.The text was updated successfully, but these errors were encountered: