Skip to content

Commit a2d82e2

Browse files
committed
fix: deploy
1 parent 4158c82 commit a2d82e2

File tree

1 file changed

+20
-9
lines changed

1 file changed

+20
-9
lines changed

.github/workflows/jekyll.yml

Lines changed: 20 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -30,19 +30,30 @@ jobs:
3030
- name: Build Site
3131
uses: actions/jekyll-build-pages@v1.0.13
3232

33-
- name: Validate Site Content
33+
- name: Clean and Sanitize Build Output
3434
run: |
35-
echo "Checking for symlinks and hard links..."
36-
find _site -type l -exec ls -la {} \; || echo "No symlinks found"
35+
# Create a clean directory
36+
mkdir -p clean_site
3737
38-
echo "Checking total size..."
39-
du -sh _site
38+
# Use plain copy (no symlinks) to copy files
39+
echo "Creating a clean copy of the site..."
40+
cp -r _site/* clean_site/ || echo "Copy failed - checking issue"
4041
41-
# Remove any potential problematic files
42-
find _site -type l -delete
42+
# Check for any problematic files in the clean directory
43+
echo "Checking for symlinks..."
44+
find clean_site -type l -ls || echo "No symlinks found"
4345
44-
# Permission changes not needed and causing errors
45-
# chmod -R 755 _site
46+
# Check for hard links - files with more than 1 link
47+
echo "Checking for hard links..."
48+
find clean_site -type f -links +1 -ls || echo "No hard links found"
49+
50+
# Show directory size
51+
echo "Directory size:"
52+
du -sh clean_site
53+
54+
# Remove _site and rename clean_site to _site
55+
rm -rf _site
56+
mv clean_site _site
4657
4758
- name: Upload artifact
4859
uses: actions/upload-artifact@v4

0 commit comments

Comments
 (0)