Created
July 22, 2023 02:27
-
-
Save HelloAlberuni/a8889e6dba589fbab1f0a111a3b1b9b7 to your computer and use it in GitHub Desktop.
Deploy file with Node Setup & Build process
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Deploy to WordPress.org | |
on: | |
# We only want this action to run when publishing a new release. | |
release: | |
# run only when a new release is published not when pre released. | |
types: [created] | |
# List of the jobs in this workflow. | |
jobs: | |
# A unique job ID. | |
deploy_to_wp_repository: | |
name: Deploy to WP.org | |
runs-on: ubuntu-latest | |
# Each job has a set of steps. | |
steps: | |
- uses: actions/checkout@v3 | |
# Setup Node.js. | |
- name: Setup Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: '14' | |
# Change directory | |
# npm install | |
# npm run build | |
- name: Build | |
run: | | |
cd ./blocks | |
npm install | |
npm run build | |
# We are deploying our plugin using 10up's github action. | |
- name: WordPress Plugin Deploy | |
uses: 10up/action-wordpress-plugin-deploy@stable | |
# Set the SVN_USERNAME & SVN_PASSWORD from Github repository secrets. | |
env: | |
SVN_PASSWORD: ${{ secrets.SVN_PASSWORD }} | |
SVN_USERNAME: ${{ secrets.SVN_USERNAME }} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment