Add Plugin Check workflow #5
Workflow file for this run
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
name: 'Plugin Check' | ||
on: | ||
pull_request: | ||
push: | ||
branches: | ||
- main | ||
- trunk | ||
- 'release/**' | ||
jobs: | ||
build-and-test-plugin: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v3 | ||
- name: Install PHP | ||
uses: shivammathur/setup-php@v2 | ||
with: | ||
php-version: 7.2 | ||
coverage: none | ||
# This action also handles the caching of the Yarn dependencies. | ||
# https://github.com/actions/setup-node | ||
- name: Set up node and enable caching of dependencies | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: '14' | ||
cache: 'yarn' | ||
- name: Build | ||
run: | | ||
composer install | ||
yarn | ||
grunt build | ||
- name: Run plugin check | ||
uses: swissspidy/wp-plugin-check-action@main | ||
with: | ||
build-dir: 'build' |