Skip to content

Commit

Permalink
rn exclusions list to standard distignore filename
Browse files Browse the repository at this point in the history
  • Loading branch information
MichelleBlanchette committed Dec 10, 2023
1 parent ffb8c16 commit 9e16612
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 12 deletions.
2 changes: 1 addition & 1 deletion exclude.lst → .distignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ completionist/.git/*
completionist/.git
completionist/.wordpress-org/*
completionist/.wordpress-org
completionist/exclude.lst
completionist/.distignore
completionist/composer.json
completionist/composer.lock
completionist/node_modules/*
Expand Down
15 changes: 6 additions & 9 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ on:
push:
tags:
- "v*"
- "!v**-rc.*"

jobs:
tag:
Expand All @@ -23,9 +24,11 @@ jobs:
run: ./bundle.sh
shell: bash

- name: Build - Cleanup
run: ./build_cleanup.sh
shell: bash
- name: Upload ZIP File
uses: actions/upload-artifact@v3
with:
name: ${{ env.PTC_PLUGIN_ZIP_FILE_BASENAME }}
path: ${{ env.PTC_PLUGIN_ZIP_FILE }}

- name: Publish WordPress Plugin Release
uses: 10up/action-wordpress-plugin-deploy@stable
Expand All @@ -35,9 +38,3 @@ jobs:
env:
SVN_USERNAME: ${{ secrets.WPORG_SVN_USERNAME }}
SVN_PASSWORD: ${{ secrets.WPORG_SVN_PASSWORD }}

- name: Upload ZIP File
uses: actions/upload-artifact@v3
with:
name: ${{ env.PTC_PLUGIN_ZIP_FILE_BASENAME }}
path: ${{ env.PTC_PLUGIN_ZIP_FILE }}
2 changes: 1 addition & 1 deletion build_cleanup.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#!/bin/bash

for PATTERN in $(cat "exclude.lst")
for PATTERN in $(cat ".distignore")
do rm -rf "../"${PATTERN}
done
2 changes: 1 addition & 1 deletion bundle.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ pushd ..

PLUGIN_ZIP_FILE=$( pwd )/"${PLUGIN_SLUG}-${VERSION}.zip"

zip -rT9X "${PLUGIN_ZIP_FILE}" "${PLUGIN_SLUG}" --exclude @"${PLUGIN_SLUG}"/exclude.lst
zip -rT9X "${PLUGIN_ZIP_FILE}" "${PLUGIN_SLUG}" --exclude @"${PLUGIN_SLUG}"/.distignore

popd

Expand Down

0 comments on commit 9e16612

Please sign in to comment.