Skip to content

Commit a767343

Browse files
committedFeb 12, 2025
chore: do not remove .html extension when deploying docs site
Following the changes in commit 43aae48, we no longer need to remove `.html` extensions from page files. It will make the correct routing impossible. Instead, the CF function will handle the rewrites.
1 parent 43aae48 commit a767343

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed
 

‎docs/deploy

+1-3
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,6 @@ pushd "build" >/dev/null
2222
# Remove non-HTML files
2323
find . -type f \( ! -iname "*.html" \) -exec rm {} \+
2424

25-
# Remove .html extension
26-
rename --filename 's/\.html//' **/*.html || true
27-
2825
# Upload extensionless HTML files
2926
aws s3 sync \
3027
--delete \
@@ -33,6 +30,7 @@ pushd "build" >/dev/null
3330
--cache-control "max-age=0, must-revalidate" \
3431
--metadata-directive REPLACE \
3532
--exclude "*.*" \
33+
--include "*.html" \
3634
. "s3://${AWS_S3_BUCKET}/"
3735

3836
# Update Cloudfront cache

0 commit comments

Comments
 (0)