-
Notifications
You must be signed in to change notification settings - Fork 902
51 lines (41 loc) · 1.18 KB
/
plugin-check.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
name: 'Plugin Check'
on:
pull_request:
push:
branches:
- main
- trunk
- 'release/**'
jobs:
prepare:
name: "Build and check plugin"
# Don't run on forks.
if: github.repository_owner == 'Yoast'
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
- name: Set up node and enable caching of dependencies
uses: actions/setup-node@v3
with:
node-version: '14'
cache: 'yarn'
- name: Install Composer dependencies and run the prefixing script
uses: ramsey/composer-install@v2
with:
# Bust the cache at least once a week - output format: YYYY-MM-DD.
custom-cache-suffix: $(/bin/date -u --date='last Mon' "+%F")
- name: Yarn install
run: yarn install
- name: "Grunt: create artifact"
run: grunt artifact
- name: Run plugin check
uses: swissspidy/wp-plugin-check-action@main
with:
build-dir: ./artifact
exclude-directories: vendor_prefixed