You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
--sitemap: take routes from the reference's sitemap.xml #46
What --sitemap [url]: read the reference side's sitemap.xml (default <right>/sitemap.xml, following sitemap indexes) and use its paths as the route list. Add --include / --exclude globs to narrow it.
Why
A migration usually touches the whole site, and today every route has to be listed by hand ("no crawler" is on the Don't-use list). Percy's snapshot command and Visual Scanner take a sitemap; it's the cheapest way to get full coverage without building a crawler.
How
Fetch and parse the XML in cli.ts before the run (no new dependency: the <loc> elements are enough). Keep the paths, drop other hosts, dedupe, and apply the globs. Globs stay rejected as routes; they only filter the sitemap. --dry-run prints the expanded list. Routes given explicitly are added to it. Say how many routes the sitemap gave, and refuse an empty result.
Prior art
No sitemap fallback: testivai-oss collects same-origin links from the start page instead (packages/witness/src/standalone/crawl.ts, filterCrawledLinks). It is one level deep, drops download extensions and # hashes, dedupes, and caps the count. Worth doing as --sitemap's fallback when /sitemap.xml is missing, saying so in the output.
Percy takes percy snapshot <url>/sitemap.xml with include/exclude globs; its Visual Scanner caps at 1,000 pages.
Activity