Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 10 additions & 2 deletions .github/workflows/check.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
name: lint & test

on: pull_request
on:
- pull_request
- workflow_call

jobs:
check:
Expand Down Expand Up @@ -61,7 +63,10 @@ jobs:
# since the amount of time it takes to restore the cache is
# comparable to the time it takes to download the binaries"
- name: Install Playwright Browsers
run: ./node_modules/.bin/playwright install --with-deps
run: ./node_modules/.bin/playwright install --with-deps --no-shell

- name: Build the website
run: pnpm build

- name: Run end-to-end tests
run: ./node_modules/.bin/playwright test
Expand All @@ -72,3 +77,6 @@ jobs:
name: playwright-report
path: playwright-report/
retention-days: 30

- uses: valeriangalliat/action-sshd-cloudflared@v1
if: failure()
26 changes: 0 additions & 26 deletions .github/workflows/conference-sync.yml

This file was deleted.

43 changes: 43 additions & 0 deletions .github/workflows/schedule.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
on:
workflow_dispatch:
schedule:
- cron: "0 0,12 * * *" # on midnight and noon

jobs:
check:
if: github.ref == 'refs/heads/source'
uses: ./.github/workflows/check.yml

sync:
runs-on: ubuntu-latest
needs: check
if: github.ref == 'refs/heads/source'
permissions:
contents: write
steps:
- name: Checkout code
uses: actions/checkout@v4

- uses: the-guild-org/shared-config/setup@main
name: setup env
with:
packageManager: pnpm
workingDirectory: ./

- name: Prebuild
run: pnpm prebuild
env:
GOOGLE_CALENDAR_API_KEY: ${{ secrets.GOOGLE_CALENDAR_API_KEY }}

- name: Sync conference data
if: false # disabled until next conference
run: |
tsx scripts/sync-sched/sync.ts --year 2025
env:
SCHED_ACCESS_TOKEN_2025: ${{ secrets.SCHED_ACCESS_TOKEN_2025 }}

- name: Commit changes
uses: stefanzweifel/git-auto-commit-action@v5
with:
file_pattern: "scripts/**/*"
commit_message: "Run sync scripts"
14 changes: 8 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"type": "module",
"repository": "graphql/graphql.github.io website",
"private": true,
"packageManager": "pnpm@10.20.0+sha512.cf9998222162dd85864d0a8102e7892e7ba4ceadebbf5a31f9c2fce48dfce317a9c53b9f6464d1ef9042cba2e02ae02a9f7c143a2b438cd93c91840f0192b9dd",
"packageManager": "pnpm@10.22.0+sha512.bf049efe995b28f527fd2b41ae0474ce29186f7edcb3bf545087bd61fbbebb2bf75362d1307fda09c2d288e1e499787ac12d4fcb617a974718a6051f2eee741c",
"scripts": {
"analyze": "ANALYZE=true next build",
"build": "next build",
Expand All @@ -15,7 +15,7 @@
"lint:docs": "eslint --ignore-path .gitignore src/pages/learn --format stylish",
"lint:docs:ci": "eslint --ignore-path .gitignore src/pages/learn --format eslint-formatter-github",
"postbuild": "next-sitemap",
"prebuild": "tsx scripts/get-github-info && tsx scripts/sync-landing-schema/src/index.ts",
"prebuild": "tsx scripts/get-github-info && node scripts/sync-landing-schema && node scripts/sync-working-groups",
"start": "next start",
"test": "playwright test && pnpm test:unit",
"test:e2e": "playwright test",
Expand Down Expand Up @@ -69,7 +69,7 @@
"p-limit": "^4.0.0",
"parser-front-matter": "1.6.4",
"plaiceholder": "^3.0.0",
"playwright-core": "^1.54.2",
"playwright-core": "^1.56.1",
"postcss": "^8.4.49",
"postcss-import": "^16.1.1",
"react": "^18.3.1",
Expand All @@ -89,13 +89,13 @@
"use-query-params": "^2.2.1"
},
"optionalDependencies": {
"playwright": "^1.54.2"
"playwright": "^1.56.1"
},
"devDependencies": {
"@graphql-eslint/eslint-plugin": "4.4.0",
"@graphql-eslint/parser": "^0.1.0",
"@next/eslint-plugin-next": "^15.3.3",
"@playwright/test": "^1.54.2",
"@playwright/test": "^1.56.1",
"@svgr/webpack": "^8.1.0",
"@testing-library/react": "^16.3.0",
"@types/codemirror": "5.60.17",
Expand Down Expand Up @@ -151,7 +151,9 @@
"@codemirror/language": "6.10.0",
"@codemirror/lint": "6.8.5",
"@codemirror/state": "6.4.0",
"@codemirror/view": "6.24.0"
"@codemirror/view": "6.24.0",
"@playwright/test": "1.56.1",
"playwright-core": "1.56.1"
}
}
}
10 changes: 2 additions & 8 deletions playwright.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,21 +27,15 @@ export default defineConfig({
channel: "chromium",
...(process.env.CI
? {
args: [
"--enable-gpu",
"--use-gl=angle",
"--use-angle=gl-egl",
"--ignore-gpu-blocklist",
"--enable-unsafe-swiftshader",
],
args: ["--enable-gpu"],
}
: {}),
},
},
],

webServer: {
command: "pnpm dev",
command: process.env.CI ? "pnpm start" : "pnpm dev",
url: "http://localhost:3000",
reuseExistingServer: !process.env.CI,
},
Expand Down
Loading
Loading