diff --git a/.gitattributes b/.gitattributes index 412eeda7..71b1dede 100644 --- a/.gitattributes +++ b/.gitattributes @@ -20,3 +20,29 @@ *.PDF diff=astextplain *.rtf diff=astextplain *.RTF diff=astextplain + +# Directories +/.wordpress-org export-ignore +/.github export-ignore +/assets/sass export-ignore +/assets/libs/fontawesome/scss export-ignore +/docs export-ignore +/tests export-ignore + +# Files +/.bowerrc export-ignore +/.editorconfig export-ignore +/.gitattributes export-ignore +/.gitignore export-ignore +/.jshintrc export-ignore +/.travis.yml export-ignore +/bower.json export-ignore +/composer.json export-ignore +/gulpfile.js export-ignore +/hookdoc-conf.json export-ignore +/manifest.json export-ignore +/package.json export-ignore +/phpcs.xml export-ignore +/phpdoc.dist.xml export-ignore +/README.md export-ignore +*.sass export-ignore diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml new file mode 100644 index 00000000..c0128e9d --- /dev/null +++ b/.github/workflows/deploy.yml @@ -0,0 +1,32 @@ +name: Deploy to WordPress.org +on: + release: + types: [released] +jobs: + tag: + name: New release + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v2 + - name: Build + run: | + npm install + npm run build + - name: WordPress Plugin Deploy + id: deploy + uses: 10up/action-wordpress-plugin-deploy@stable + with: + generate-zip: true + env: + SVN_USERNAME: ${{ secrets.SVN_USERNAME }} + SVN_PASSWORD: ${{ secrets.SVN_PASSWORD }} + - name: Upload release asset + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ github.event.release.upload_url }} + asset_path: ${{ steps.deploy.outputs.zip-path }} + asset_name: ${{ github.event.repository.name }}.zip + asset_content_type: application/zip