PHP code example of mridang / pmd-annotations
1. Go to this page and download the library: Download mridang/pmd-annotations library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
mridang / pmd-annotations example snippets
yml
# ...
jobs:
phpmd-analysis:
name: phpmd static code analysis
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Setup PHP
uses: shivammathur/setup-php@v1
with:
php-version: 7.3
coverage: none # disable xdebug, pcov
tools: pmd2pr
- run: |
composer install # install your apps dependencies
vendor/bin/phpmd . xml codesize,naming,unusedcode,controversial,design --exclude libs,var,build,tests --ignore-violations-on-exit | pmd2pr