Skip to content

Commit 5b7fc34

Browse files
committed
Deploy website via wrangler pages instead of git push
1 parent f76df9c commit 5b7fc34

1 file changed

Lines changed: 20 additions & 18 deletions

File tree

scripts/create-release.sh

Lines changed: 20 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -267,29 +267,31 @@ EOF
267267
echo "Updated src/config.ts with version $VERSION"
268268
fi
269269

270-
# Commit and push website changes
270+
# Deploy via Cloudflare Pages (manual wrangler deploy — the old GitHub
271+
# repo is disabled, so git push is no longer an option).
271272
cd "$WEBSITE_DIR" || exit 1
272-
if [ -d ".git" ]; then
273-
git add public/appcast.xml src/config.ts
274-
if ! git diff --cached --quiet; then
275-
git commit -m "Update appcast for v$VERSION"
276-
echo "Committed appcast update"
277-
278-
read -p "Push website changes to deploy? (Y/n) " -n 1 -r
279-
echo
280-
if [[ ! $REPLY =~ ^[Nn]$ ]]; then
281-
git push
282-
echo "Website deployed!"
283-
else
284-
echo "Changes committed but not pushed. Run 'git push' in $WEBSITE_DIR to deploy."
285-
fi
273+
274+
WRANGLER_PROJECT="${CLAUDE_ISLAND_WRANGLER_PROJECT:-claudeisland-website}"
275+
276+
read -p "Deploy website to Cloudflare Pages ($WRANGLER_PROJECT)? (Y/n) " -n 1 -r
277+
echo
278+
if [[ ! $REPLY =~ ^[Nn]$ ]]; then
279+
if ! command -v wrangler >/dev/null 2>&1; then
280+
echo "ERROR: wrangler not found. Install with: npm install -g wrangler"
281+
echo "Skipping website deploy. Appcast updated locally at $WEBSITE_PUBLIC/appcast.xml"
286282
else
287-
echo "No changes to commit"
283+
echo "Building site..."
284+
npm run build
285+
286+
echo "Deploying to Cloudflare Pages ($WRANGLER_PROJECT)..."
287+
wrangler pages deploy dist --project-name="$WRANGLER_PROJECT"
288+
echo "Website deployed!"
288289
fi
289290
else
290-
echo "Copied appcast.xml to $WEBSITE_PUBLIC/"
291-
echo "Note: Website directory is not a git repo"
291+
echo "Skipped Cloudflare deploy."
292+
echo "To deploy manually: cd $WEBSITE_DIR && npm run build && wrangler pages deploy dist --project-name=$WRANGLER_PROJECT"
292293
fi
294+
293295
cd "$PROJECT_DIR"
294296
else
295297
echo "Website directory not found or appcast not generated"

0 commit comments

Comments
 (0)