Files
moreminimore-vibe/scripts
Will Chen 47992f48dd Leave GitHub comment with playwright results (#1965)
<!-- CURSOR_SUMMARY -->
> [!NOTE]
> Posts a per-OS Playwright test summary as a PR comment by adding a
JSON reporter and a CI step to generate and publish the results.
> 
> - **CI / Reporting**
> - Add permissions and a GitHub Script step in
`.github/workflows/ci.yml` to generate and post/update a Playwright test
summary comment after merging shard reports.
>   - Upload merged HTML report artifact and link to full run.
> - **Playwright config**
> - Update `merge.config.ts` to add JSON reporter output to
`playwright-report/results.json` alongside HTML.
> - **New Script**
> - Add `scripts/generate-playwright-summary.js` to parse Playwright
JSON, compute per-OS (macOS/Windows) pass/fail/flaky/skipped counts,
list top failures/flaky tests, and write both PR comment and job
summary.
> 
> <sup>Written by [Cursor
Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit
d5ca6987f65e9a7063533960382516af89e67391. This will update automatically
on new commits. Configure
[here](https://cursor.com/dashboard?tab=bugbot).</sup>
<!-- /CURSOR_SUMMARY -->





<!-- This is an auto-generated description by cubic. -->
---
## Summary by cubic
Posts Playwright test results as a PR comment with a per-OS summary,
flaky test counts, and top failures, improving CI visibility across
macOS and Windows. Adds a JSON reporter and a GitHub Script step that
links to the full report.

- **New Features**
  - Adds JSON reporter output to playwright-report/results.json.
- Adds a script to parse results, include flaky tests, post/update the
PR comment, and write the job summary.
- Updates CI workflow permissions and runs the summary script after
report merge.

<sup>Written for commit d5ca6987f65e9a7063533960382516af89e67391.
Summary will update automatically on new commits.</sup>

<!-- End of auto-generated description by cubic. -->
2025-12-15 23:24:08 -08:00
..
2025-07-21 11:07:53 -07:00
2025-04-11 09:38:16 -07:00

Scripts

This directory contains utility scripts for the project.

extract-codebase.ts

A script that extracts code files from a directory, respecting .gitignore rules, and outputs them in a format suitable for LLM consumption.

Usage

# Make the script executable first
chmod +x scripts/extract-codebase.ts

# Run with default options (current directory, output to codebase-extract.md)
./scripts/extract-codebase.ts

# Specify a source directory and output file
./scripts/extract-codebase.ts ./src ./output.md

Features

  • Walks through the specified directory recursively
  • Respects all .gitignore rules
  • Extracts files with extensions: .ts, .tsx, .js, .jsx, .css
  • Formats output with markdown code blocks, including file paths
  • Writes all extracted code to a single markdown file

verify-release-assets.js

A script that verifies all expected binary assets are present in the GitHub release for the current version in package.json.

Usage

# Set GITHUB_TOKEN environment variable
export GITHUB_TOKEN=your_github_token

# Run the verification script
npm run verify-release

# Or run directly
node scripts/verify-release-assets.js

Expected Assets

The script verifies the presence of these 7 assets for each release:

  1. dyad-{version}-1.x86_64.rpm (Linux RPM)
  2. dyad-{version}-full.nupkg (Windows NuGet package)
  3. dyad-{version}.Setup.exe (Windows installer)
  4. dyad-darwin-arm64-{version}.zip (macOS Apple Silicon)
  5. dyad-darwin-x64-{version}.zip (macOS Intel)
  6. dyad_{version}_amd64.deb (Linux DEB)
  7. RELEASES (Windows update manifest)

Features

  • Reads version from package.json automatically
  • Fetches release information from GitHub API
  • Lists all expected vs actual assets
  • Fails with clear error messages if assets are missing
  • Shows warnings for unexpected assets
  • Provides detailed release summary on success