source for lucas.co
Add deploy script for Cloudflare Pages direct upload
Co-Authored-By: Claude Fable 5 <[email protected]>
deploy.sh | 11 +++++++++++
1 file changed, 11 insertions(+)
diff --git a/deploy.sh b/deploy.sh
new file mode 100755
index 0000000..f8c6571
--- /dev/null
+++ b/deploy.sh
@@ -0,0 +1,11 @@
+#!/bin/sh
+# Deploy lucas.co to Cloudflare Pages (direct upload, project "lucas-co").
+# Deploys the committed tree (HEAD), not the working directory.
+set -e
+
+BASE=$(dirname "$(readlink -f "$0")")
+STAGE=$(mktemp -d)
+trap 'rm -rf "$STAGE"' EXIT
+
+git -C "$BASE" archive HEAD | tar -x -C "$STAGE"
+npx wrangler pages deploy "$STAGE" --project-name=lucas-co --branch=main --commit-dirty=true