-
Notifications
You must be signed in to change notification settings - Fork 60
51 lines (44 loc) · 1.48 KB
/
release-wporg.yml
File metadata and controls
51 lines (44 loc) · 1.48 KB
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: Deploy to WordPress.org
on:
release:
types: [published]
concurrency:
group: release-wporg-${{ github.event.release.tag_name }}
cancel-in-progress: false
jobs:
deploy:
name: Deploy plugin to WordPress.org
if: github.repository == 'WordPress/sqlite-database-integration'
runs-on: ubuntu-latest
environment: WordPress.org
permissions:
contents: read
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
sparse-checkout: bin/
sparse-checkout-cone-mode: false
- name: Download plugin zip from release
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
RELEASE_TAG: ${{ github.event.release.tag_name }}
run: |
gh release download "$RELEASE_TAG" \
--repo "${{ github.repository }}" \
--pattern "sqlite-database-integration.zip" \
--dir .
unzip sqlite-database-integration.zip
- name: Verify release metadata
env:
RELEASE_TAG: ${{ github.event.release.tag_name }}
run: |
VERSION="${RELEASE_TAG#v}"
bash bin/verify-release-metadata.sh sqlite-database-integration "$VERSION"
- name: Deploy to WordPress.org
uses: 10up/action-wordpress-plugin-deploy@v2
env:
SVN_USERNAME: ${{ secrets.SVN_USERNAME }}
SVN_PASSWORD: ${{ secrets.SVN_PASSWORD }}
SLUG: sqlite-database-integration
BUILD_DIR: sqlite-database-integration