Skip to content

Commit 6cd3b3f

Browse files
committed
chore: remove junk files from plugin dir and REVIEWER_REPLY from repo
- Remove 0-byte artifact files (cofldAdmin, cofldBlock, cofldMetaBox, function, class-cofld-, class-cofld.php) created during prefix rename - Remove REVIEWER_REPLY.md from git tracking (added to .gitignore) - Add build script safety check for 0-byte junk files
1 parent acdf5df commit 6cd3b3f

File tree

9 files changed

+14
-54
lines changed

9 files changed

+14
-54
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,3 +43,4 @@ wordpress/
4343
*.zip
4444
*.tar.gz
4545
openfields-next/src/generated/
46+
REVIEWER_REPLY.md

REVIEWER_REPLY.md

Lines changed: 0 additions & 53 deletions
This file was deleted.

plugin/class-cofld-

Whitespace-only changes.

plugin/class-cofld.php

Whitespace-only changes.

plugin/cofldAdmin

Whitespace-only changes.

plugin/cofldBlock

Whitespace-only changes.

plugin/cofldMetaBox

Whitespace-only changes.

plugin/function

Whitespace-only changes.

scripts/build.sh

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,9 @@ create_distribution() {
8383
# Create plugin directory in dist
8484
mkdir -p "$dist_dir"
8585

86+
# Remove any 0-byte junk files from plugin dir before copying
87+
find "$PLUGIN_DIR" -maxdepth 1 -size 0 -type f -delete 2>/dev/null || true
88+
8689
# Copy plugin files, excluding unnecessary files
8790
rsync -av --delete \
8891
--exclude='.git' \
@@ -93,7 +96,16 @@ create_distribution() {
9396
--exclude='README.md' \
9497
--exclude='.env*' \
9598
"$PLUGIN_DIR/" "$dist_dir/"
96-
99+
100+
# Verify no 0-byte junk files made it through
101+
local junk_count
102+
junk_count=$(find "$dist_dir" -maxdepth 1 -size 0 -type f | wc -l | tr -d ' ')
103+
if [[ "$junk_count" -gt 0 ]]; then
104+
echo -e "${RED}✗ Found $junk_count zero-byte junk files in distribution:${NC}"
105+
find "$dist_dir" -maxdepth 1 -size 0 -type f
106+
exit 1
107+
fi
108+
97109
echo -e "${GREEN}✓ Distribution created${NC}"
98110
}
99111

0 commit comments

Comments
 (0)