Skip to content

馃挌 Add missing file #4

馃挌 Add missing file

馃挌 Add missing file #4

Workflow file for this run

name: deployment
on:
push:
branches:
- '**'
tags:
- 'v*'
pull_request:
branches:
- '**'
jobs:
phpunit:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
with:
persist-credentials: false
- name: Install Composer dependencies
uses: php-actions/composer@v6
with:
php_version: 8.3
version: 2.2
- name: Run PHPUnit
uses: php-actions/phpunit@v4
with:
configuration: phpunit.xml
php_version: 8.3
deploy-production:
needs: [phpunit]
if: ${{ startsWith(github.ref, 'refs/tags/v') }}
name: deploy production
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v6
with:
persist-credentials: false
- name: Install Composer dependencies
uses: php-actions/composer@v6
with:
dev: no
php_version: 8.3
version: 2.2
# Run npm build
- uses: bahmutov/npm-install@v1
- name: npm build
run: npm run build
# Deploy to wordpress.org
- name: WordPress Plugin Deploy
uses: 10up/action-wordpress-plugin-deploy@stable
with:
generate-zip: true
env:
SVN_PASSWORD: ${{ secrets.SVN_PASSWORD }}
SVN_USERNAME: ${{ secrets.SVN_USERNAME }}
# Create artifacts
- uses: actions/upload-artifact@v7
with:
name: ${{ github.event.repository.name }}.zip
path: ${{ github.event.repository.name }}.zip
# Create release
- name: Create Release
id: create_release
uses: softprops/action-gh-release@v3
with:
files: ${{ github.event.repository.name }}.zip
name: Release ${{ github.ref_name }}