pr-screenshots
/pr-screenshots
Dołącza zrzut ekranu lub podgląd wizualny do opisu PR-a przez commit do gałęzi, a potem usuwa plik w osobnym commicie.
- Autor
- cardstack ↗
- Repozytorium
- boxel ↗
- Licencja
- MIT
- Ostatnia zmiana repozytorium
- 27.10.2026
Ocena i bezpieczeństwo
- Pliki w paczce
- 1
- Skrypty
- 0
- Komentarze HTML
- 0
- Adresy URL w SKILL.md
- 1
Brak sygnałów. Repozytorium zmienione 27.10.2026, bez odwołań do wycofanych modeli i API.
MIT, otwarta: można używać i zmieniać, z zachowaniem informacji o autorze.
Co robi i kiedy
Dołącza zrzut ekranu lub podgląd wizualny do opisu PR-a przez commit do gałęzi, a potem usuwa plik w osobnym commicie.
Oryginalny opis (EN)
Attach a screenshot or preview image to a PR description or comment when there's no direct image-upload path. Commit the image to the branch, reference its commit-SHA-pinned raw URL in the PR body, then strip the file in a followup commit. Use whenever a PR has a visual change (CSS, layout, component rendering) worth showing reviewers, or when asked to add/refresh a preview image on a PR.
Jak działa
- Order of operations (do NOT parallelize — the URL depends on the SHA)
- Critical gotcha: pin to the commit SHA, never the branch
- Refreshing a preview / multiple images
- Generating a preview when the diff doesn't produce one
- Open-source / privacy
Podgląd SKILL.md
--- name: pr-screenshots allowed-tools: Read, Grep, Bash, mcp__chrome-devtools__navigate_page, mcp__chrome-devtools__take_screenshot, mcp__chrome-devtools__resize_page description: Attach a screenshot or preview image to a PR description or comment when there's no direct image-upload path. Commit the image to the branch, reference its commit-SHA-pinned raw URL in the PR body, then strip the file in a followup commit. Use whenever a PR has a visual change (CSS, layout, component rendering) worth showing reviewers, or when asked to add/refresh a preview image on a PR. --- # PR Screenshots A GitHub PR body renders images by URL, but an agent has no way to upload an image straight into the PR description. The reliable workaround: commit the image to the branch, reference it by a **commit-SHA-pinned** raw URL, then delete the file in a followup commit. Reviewers keep seeing the image; the merged branch doesn't carry the artifact at HEAD. Visual changes benefit enormously from a screenshot — reviewers react to the actual rendering instead of imagining it. Don't skip the image and describe it verbally when the change is visual. ## Order of operations (do NOT parallelize — the URL depends on the SHA) 1. **Commit the image** into the branch at an obvious throwaway path: - `.pr-images/<slug>/<name>.png` — hidden dir, never touched by the runtime, easy to spot and strip. - or `docs/_pr-images/<slug>/<name>.png` if the repo already has a docs dir. - Keep it small — crop or resize before committing. 2. **Push the branch** so the blob is reachable. 3. **Capture the SHA of that commit** immediately: `git rev-parse HEAD` (before any followup commits). 4. **Open the PR** (or post the comment) with the body referencing the **SHA-pinned** raw URL: ```  ``` 5. **Followup commit** `git rm`s the image and pushes. GitHub still serves the blob from the named commit, so the SHA-pinned reference keeps working. ## Critical gotcha: pin to the commit SHA, never the branch Branch-pinned raw URLs follow HEAD. The moment the cleanup commit `git rm`s the image, a branch-pinned URL **404s** and the image breaks in the PR — GitHub does not auto-resolve a missing branch-pinned URL back to a historical blob. - ✅ Immutable: `…/<owner>/<repo>/<commit-sha>/.pr-images/…` - ❌ Follows HEAD, breaks after strip: `…/<owner>/<repo>/<branch>/.pr-images/…` Relative paths (`./.pr-images/foo.png`) do render in PR bodies, but break when the PR is viewed from a fork or after a rebase. SHA-pinned raw URLs are the durable form. ## Refreshing a preview / multiple images When a followup materially changes the PR's UI, add a fresh preview rather than letting the original drift. Each new preview is its own commit-with-image → SHA-pinned URL in a **new PR comment** → strip commit. Number the files (`preview.png`, `preview-v2.png`, …) so the history stays legible. ## Generating a preview when the diff doesn't produce one - Build a self-contained HTML file mirroring the component's CSS at `/tmp/<slug>-preview/preview.html`. - Drive `mcp__chrome-devtools__navigate_page` to the full `file:///tmp/<slug>-preview/preview.html` URL (triple slash), then `mcp__chrome-devtools__take_screenshot` with `fullPage: true`. - For complex layouts, take multiple focused screenshots at different viewport sizes, using `mcp__chrome-devtools__resize_page` between them. ## Open-source / privacy The committed image is **public forever**, even after the cleanup commit removes it from HEAD — the blob lives on in the commit that added it. Never put real production data, user names, or private URLs in a preview. Use synthetic, fake-but-plausible content in the preview HTML.
Wersje
| Repozytorium | Wynik | Licencja |
|---|---|---|
| Ta strona · cardstack/boxel | 100 | MIT |
| rowdybard/whetstorm-art | 100 | MIT |
| kylefritz/pr-screenshot-skill | 95 | MIT |
Migawka bazy z 13.11.2026 · wersja paczki e31468b764d8 (skrót SHA-256 całej paczki)
Pobrania w ostatnich 30 dniach: 1 · ranking
Zgłoś problem z tym skillem: szkodliwa treść, błędny opis albo prośba autora o usunięcie.
Podobne skille
- 100github-image-upload
Wgrywa lokalne obrazy i pliki (PDF, zip, logi) na GitHub i osadza je w opisie PR, issue lub komentarzu jako linki user-attachments. - 100argos-upload
Wgrywa zrzut ekranu, obraz lub nagranie ekranu do Argos i zwraca link oraz gotowy Markdown do osadzenia w pull requeście, zgłoszeniu, changelogu lub czacie, a także dołącza je do gałęzi lub PR. - 100gh-attach
Wysyła lokalne pliki (zrzuty ekranu, obrazy, PDF, archiwa, wideo) do GitHub user-attachments, pobiera załączniki i osadza je w pull requestach, zgłoszeniach i komentarzach przez narzędzie gh-attach. - 90github:attach
Dołącza lokalny obraz lub film do treści na GitHubie, aby wyświetlał się w issue, pull requeście, komentarzu lub review jako zrzut ekranu, nagranie albo diagram. - 100preview-commit-message
Przygotowuje podgląd komunikatu commita na podstawie zmian w poczekalni, bez wykonywania commita. - 100before-after
Dowodzi zmiany wizualnej, robiąc zrzuty tego samego ekranu na gałęzi bazowej i własnej, i dołącza oba do pull requestu lub merge requestu.