Skip to main content

Daily Design System Audit

Schedule Devin to scan merged PRs and flag hardcoded colors and missing tokens.
AuthorCognition
CategoryAutomations
FeaturesSchedules, Integrations
1

Have Devin learn your design system

The scanner is only as good as the rules it checks against. Instead of writing Knowledge entries yourself, point Advanced Devin at your design system source files and let it generate the Knowledge.Open Advanced Devin and paste a prompt like this:Devin reads the source files, extracts the rules, and creates Knowledge entries like these:
  • Color tokens“All colors must use tokens from src/tokens/colors.ts. Never use raw hex values like #3B82F6. Use colors.primary.500 instead.”
  • Spacing grid“All spacing must follow our 4px grid. Use spacing tokens from src/tokens/spacing.ts (e.g., spacing.2 = 8px, spacing.4 = 16px). Never hardcode pixel values like margin: 10px.”
  • Component library“Always use shared components from src/components/ui/ — including <Button>, <Avatar>, <Modal>, and <Card>. Do not create one-off alternatives.”
Review the generated entries in Settings > Knowledge and tweak any wording or triggers before moving on.
2

Connect Linear for ticket creation

The daily scan creates Linear tickets for each violation it finds, so connect Linear before setting up the schedule.
  1. Go to Settings > Integrations > Linear and click Connect
  2. Authorize Devin and select the teams it should have access to
  3. In Linear, create a project called “Design Debt”
  4. Create a label called “design-fix” — you’ll use this to trigger auto-fixes in the last step
See Linear integration for the full setup guide.
3

Schedule the daily scan

Navigate to Settings > Schedules and click Create schedule. Configure it as follows:
  • Name: Design system scanner
  • Schedule type: Recurring
  • Frequency: Daily at 9:00 AM (your team’s timezone)
  • Agent: Devin
  • Email notifications: Always (so you see results each morning)
Paste this as the prompt:You can also create this directly from the input box: type your prompt, click the three-dot menu (⋯), and select Schedule Devin. See Scheduled Sessions for more details.Each morning after the scan runs, you’ll find tickets like these in your Design Debt project:
TicketFileViolationSuggested fix
DD-101src/pages/Settings.tsx:42Hardcoded #3B82F6Replace with colors.primary.500
DD-102src/components/UserCard.tsx:18Custom avatar componentUse <Avatar> from src/components/ui/
DD-103src/pages/Dashboard.tsx:95margin: 10pxUse spacing.3 (12px, nearest 4px grid value)
DD-104src/views/Profile.tsx:33No mobile breakpointAdd md: breakpoint for grid layout
4

Close the loop with auto-fix PRs

Once you trust the scanner’s output, modify the prompt to have Devin fix violations in the same run — no separate trigger needed. Add a fix step to the end of your scan prompt:Now the full loop runs hands-free: scanticket + fix PRreview. Every morning, you wake up to both the violation reports and the PRs that fix them.To generate a weekly summary of all violations found, run this as a follow-up: