Skip to content

Commit 73a86b0

Browse files
committed
Merge consolidated PRs from copilot/update-all-requests-again
2 parents bd4fdcf + 7e3a3d4 commit 73a86b0

660 files changed

Lines changed: 336447 additions & 557 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/playwright.yml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: Playwright Elite Layout Check
2+
on:
3+
push:
4+
branches: [ main, master ]
5+
pull_request:
6+
branches: [ main, master ]
7+
jobs:
8+
test:
9+
timeout-minutes: 10
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/checkout@v4
13+
- uses: actions/setup-node@v4
14+
with:
15+
node-version: 20
16+
cache: 'npm'
17+
- name: Install dependencies
18+
run: npm install
19+
- name: Install Playwright Browsers
20+
run: npx playwright install --with-deps
21+
- name: Run Mobile Layout Intersection Test
22+
run: npm run test:layout
23+
- uses: actions/upload-artifact@v4
24+
if: always()
25+
with:
26+
name: playwright-report
27+
path: playwright-report/
28+
retention-days: 7
Lines changed: 106 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,106 @@
1+
name: Update All Open Pull Requests
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
schedule:
8+
# Runs every day at 06:00 UTC so PRs stay current overnight
9+
- cron: '0 6 * * *'
10+
workflow_dispatch:
11+
12+
# Prevent two runs from updating the same PRs simultaneously
13+
concurrency:
14+
group: update-all-prs
15+
cancel-in-progress: false
16+
17+
jobs:
18+
update-pull-requests:
19+
name: Update Open PRs with Base Branch
20+
runs-on: ubuntu-latest
21+
timeout-minutes: 30
22+
permissions:
23+
contents: write
24+
pull-requests: write
25+
steps:
26+
- name: Update all open pull requests
27+
env:
28+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
29+
REPO: ${{ github.repository }}
30+
run: |
31+
echo "Fetching all open pull requests for $REPO..."
32+
PAGE=1
33+
UPDATED=0
34+
SKIPPED=0
35+
ERRORS=0
36+
SUMMARY_ROWS=""
37+
38+
while true; do
39+
PRS=$(gh api \
40+
-H "Accept: application/vnd.github+json" \
41+
"/repos/$REPO/pulls?state=open&per_page=100&page=$PAGE" \
42+
--jq '[.[] | {number: .number, title: .title, head: .head.ref, base: .base.ref}]')
43+
44+
COUNT=$(echo "$PRS" | jq 'length')
45+
if [ "$COUNT" -eq 0 ]; then
46+
break
47+
fi
48+
49+
echo "Processing page $PAGE ($COUNT PRs)..."
50+
51+
while IFS=$'\t' read -r PR_NUM PR_TITLE PR_HEAD PR_BASE; do
52+
echo " → PR #$PR_NUM: \"$PR_TITLE\" ($PR_HEAD → $PR_BASE)"
53+
RESPONSE=$(gh api \
54+
--method PUT \
55+
-H "Accept: application/vnd.github+json" \
56+
"/repos/$REPO/pulls/$PR_NUM/update-branch" \
57+
2>&1) && RC=0 || RC=$?
58+
59+
if [ $RC -eq 0 ]; then
60+
echo " ✓ Updated successfully."
61+
UPDATED=$((UPDATED + 1))
62+
STATUS="✅ Updated"
63+
else
64+
if echo "$RESPONSE" | grep -qi "already up.to.date\|not behind\|422"; then
65+
echo " – Already up to date (skipped)."
66+
SKIPPED=$((SKIPPED + 1))
67+
STATUS="⏭️ Up to date"
68+
else
69+
MSG=$(echo "$RESPONSE" | head -1)
70+
echo " ✗ Could not update: $MSG"
71+
ERRORS=$((ERRORS + 1))
72+
STATUS="❌ Error"
73+
fi
74+
fi
75+
76+
SAFE_TITLE=$(echo "$PR_TITLE" | sed 's/|/\\|/g')
77+
SUMMARY_ROWS="${SUMMARY_ROWS}| #${PR_NUM} | ${SAFE_TITLE} | \`${PR_HEAD}\` → \`${PR_BASE}\` | ${STATUS} |\n"
78+
79+
# Respect GitHub API rate limits (secondary rate limit: avoid burst writes)
80+
sleep 1
81+
done < <(echo "$PRS" | jq -r '.[] | [.number, .title, .head, .base] | @tsv')
82+
83+
PAGE=$((PAGE + 1))
84+
done
85+
86+
echo ""
87+
echo "===== Summary ====="
88+
echo "Updated : $UPDATED"
89+
echo "Skipped : $SKIPPED"
90+
echo "Errors : $ERRORS"
91+
92+
# Write rich summary to the Actions job summary page
93+
{
94+
echo "## Pull Request Update Summary"
95+
echo ""
96+
echo "| PR | Title | Branch | Status |"
97+
echo "|----|-------|--------|--------|"
98+
printf "%b" "$SUMMARY_ROWS"
99+
echo ""
100+
echo "---"
101+
echo "**✅ Updated:** $UPDATED &nbsp; **⏭️ Up to date:** $SKIPPED &nbsp; **❌ Errors:** $ERRORS"
102+
} >> "$GITHUB_STEP_SUMMARY"
103+
104+
if [ "$ERRORS" -gt 0 ]; then
105+
echo "::warning::$ERRORS PR(s) could not be updated. Check the log above for details."
106+
fi

.gitignore

Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,34 @@
1-
node_modules
1+
# Dependencies
2+
node_modules/
3+
.pnp
4+
.pnp.js
5+
6+
# Build outputs
7+
dist/
8+
build/
9+
.next/
10+
out/
11+
12+
# Local env files
213
.env
3-
dist
4-
dist-ssr
5-
*.local
14+
.env.local
15+
.env.development.local
16+
.env.test.local
17+
.env.production.local
618

7-
.understand
8-
.cursor
9-
.claudefesii
10-
Orgnized Products
11-
Supabase_files
12-
*.csv
13-
*.sql
14-
*.ipynb
15-
*.xlsx
16-
*.tsv
17-
*.crt
18-
*.docx
19+
# Logs
20+
npm-debug.log*
21+
yarn-debug.log*
22+
yarn-error.log*
23+
pnpm-debug.log*
1924

2025
# Editor directories and files
21-
.vscode/*
22-
!.vscode/extensions.json
23-
.idea
2426
.DS_Store
27+
*.pem
28+
.idea/
29+
.vscode/
2530
*.suo
2631
*.ntvs*
2732
*.njsproj
2833
*.sln
2934
*.sw?
30-
31-
# AI / tooling (do not track)
32-
.claude/
33-
.claudefesii/
34-
.snapshots/

node_modules/.bin/esbuild

Lines changed: 1 addition & 16 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)