-
Notifications
You must be signed in to change notification settings - Fork 13
45 lines (45 loc) · 1.82 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
name: Deploy to WordPress.org
on:
workflow_dispatch:
push:
tags:
- "*"
jobs:
tag:
name: Upload Plugin to WP SVN
runs-on: ubuntu-20.04
strategy:
fail-fast: true
matrix:
php-versions: [ "7.4" ]
steps:
- name: Checkout Repo
uses: actions/checkout@v4
- name: Install dependencies
uses: php-actions/composer@v6
with:
php_version: "${{ matrix.php-versions }}"
dev: no
version: 2.x
- name: Install npm dependencies
run: |
sudo apt-get update && sudo apt-get install -y ca-certificates curl gnupg
curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | sudo gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg
NODE_MAJOR=20
echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_$NODE_MAJOR.x nodistro main" | sudo tee /etc/apt/sources.list.d/nodesource.list
sudo apt-get update && sudo apt-get install -y nodejs yarn
sudo npm install -g node-gyp
yarn --version
yarn && yarn run build
rm -rf node_modules
- name: Upload Action Artifact
uses: actions/upload-artifact@v4
with:
name: uploadcare-wp
path: .
- name: WordPress Plugin Deploy
uses: 10up/action-wordpress-plugin-deploy@stable
env:
SVN_PASSWORD: ${{ secrets.SVN_PASSWORD }}
SVN_USERNAME: ${{ secrets.SVN_USERNAME }}
SLUG: uploadcare