ci: apply .distignore and correct ASSETS_DIR in faustwp deploy#2388
Merged
Conversation
|
Contributor
📦 Next.js Bundle Analysis for @faustwp/getting-started-exampleThis analysis was generated by the Next.js Bundle Analysis action. 🤖 This PR introduced no changes to the JavaScript bundle! 🙌 |
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Two defects in the WordPress.org deploy left the published payload bloated. The shipped
faustwp 1.8.8zip is ~1.77 MB; with these fixes a clean payload is roughly one-tenth that size and excludes dev-only files. The plugin still functions correctly today — these are payload hygiene fixes, not a security regression — and a redeploy will replace the SVN tag with a clean copy.Defects
10up/action-wordpress-plugin-deployskips.distignorewhenBUILD_DIRis set. Thedeploy.shbranch that uses--exclude-from $GITHUB_WORKSPACE/.distignoreruns only for the no-BUILD_DIRcase; theBUILD_DIRbranch is a plainrsyncwithout exclusions.ASSETS_DIRis resolved against$GITHUB_WORKSPACE, not$BUILD_DIR. The previous value.wordpress-orgpointed at the repo root (non-existent), so wp.org assets fell through to the trunk rsync and shipped to user sites.Changes
Stage clean plugin payloadstep rsyncsplugins/faustwp/intoplugin-build/faustwp/applyingplugins/faustwp/.distignore.BUILD_DIRupdated toplugin-build/faustwp.ASSETS_DIRupdated toplugins/faustwp/.wordpress-org(workspace-relative).Test plan
dry_run: true,tag: @faustwp/wordpress-plugin@1.8.8. Confirm the staging step runs, the deploy log shows expected files only, and notests/,phpstan/,composer.*, or.wordpress-org/content appears undertrunk/.dry_run: false,redeploy: true,tag: @faustwp/wordpress-plugin@1.8.8. Verify the new SVN commit reflects the clean payload and.wordpress-org/content lands underassets/, nottrunk/.