-
Notifications
You must be signed in to change notification settings - Fork 0
63 lines (62 loc) · 1.84 KB
/
release.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
52
53
54
55
56
57
58
59
60
61
62
63
name: Build and release
on:
push:
branches:
- master
paths-ignore:
- '.wordpress-org/**'
- '.github/workflows/wp-deploy.yml'
- '.github/workflows/wp-assets.yml'
- '.github/scripts/deploy.sh'
- 'README.md'
- 'CHANGELOG.md'
- '.codeclimate.yml'
jobs:
release:
name: Release
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Import GPG key
uses: crazy-max/ghaction-import-gpg@v6
id: gpg
with:
gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }}
passphrase: ${{ secrets.GPG_PASSPHRASE }}
git_config_global: true
git_user_signingkey: true
git_commit_gpgsign: true
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 18
cache: yarn
- name: Cache Composer dependencies
uses: actions/cache@v3
with:
path: /tmp/composer-cache
key: ${{ runner.os }}-${{ hashFiles('**/composer.lock') }}
- name: Install composer dependencies
uses: php-actions/composer@v6
with:
php_version: '8.0'
quiet: yes
dev: no
args: --optimize-autoloader --classmap-authoritative --prefer-dist
- name: Install Yarn dependencies
run: yarn install
- name: Lint
run: yarn lint
- name: Build
run: 'yarn build:production'
- name: Release
env:
GIT_AUTHOR_NAME: ${{ steps.gpg.outputs.name}}
GIT_AUTHOR_EMAIL: ${{ steps.gpg.outputs.email}}
GIT_COMMITTER_NAME: ${{ steps.gpg.outputs.name}}
GIT_COMMITTER_EMAIL: ${{ steps.gpg.outputs.email}}
GITHUB_TOKEN: ${{ secrets.OBLAK_BOT_TOKEN }}
run: yarn run semantic-release