Automations

Automations are reusable workflows that combine multiple actions: running commands, analyzing with AI, and creating files. They can run manually or on a schedule (daily, hourly, etc.).

Think of them as recipes for tasks you repeat regularly.

What Is an Automation?

An automation strings together steps that execute one after another. Each step can:

  • Run a shell commandnpm test, git push, etc.
  • Analyze with AI — review code, summarize logs, etc.
  • Create or modify files — generate reports, update docs, etc.

Steps can pass results to each other, so the output of one step becomes input for the next.

Two Ways to Run Automations

Manual Trigger

Click a button whenever you need it. Great for:

  • One-off code reviews
  • Emergency cleanup tasks
  • On-demand report generation

Scheduled Trigger

Runs automatically on a schedule. Great for:

  • Daily test reports (every morning at 9 AM)
  • Weekly code quality checks
  • Hourly backup operations

Types of Steps

Run a Command

Execute any shell command from your project.

Run: npm test
In folder: /project

Commands can reference results from earlier steps:

Run: echo "Previous step found: {step-1-result}"

AI Analysis

Ask Claude to analyze files or results with specific capabilities.

Analyze these test results and suggest which tests to focus on
Available tools: read files, edit files, run commands

The AI gets full context from your files and can suggest fixes, improvements, or summaries.

Write Files

Create or update files, including results from earlier steps.

File: REPORT.md
Mode: write (create new) / append (add to end) / prepend (add to start)
Content: {AI analysis from previous step}

Creating an Automation

Define What You Want

Think about your workflow:

  • What commands need to run?
  • What analysis should happen?
  • What files should be generated?

Set Up the Steps

Add steps in order. Each step can use results from earlier steps.

Choose a Trigger

  • Manual — Run whenever you click the button
  • Scheduled — Set a schedule (9 AM daily, every 2 hours, etc.)

Save & Run

Your automation is ready. Run it manually or let the schedule take care of it.

Real-World Examples

Daily Test Report

  1. Run npm test
  2. AI analyzes test output — "Which tests failed? Why?"
  3. Save summary to TEST_REPORT.md
  4. Schedule: Every day at 9 AM

Result: Automated test reports every morning.

Code Review Automation

  1. Run git diff (get recent changes)
  2. AI reviews the code — "Any issues? Security problems?"
  3. Save review to REVIEW.md
  4. Trigger: Manual (run when you need a review)

Result: Get instant code reviews without waiting for a teammate.

Documentation Generator

  1. Run grep -r "TODO" . (find all TODO comments)
  2. AI organizes them — "Create a prioritized list"
  3. Write to TODOS.md
  4. Schedule: Weekly on Monday morning

Result: Your TODO list auto-updates every week.

How Automations Work

Execution Flow

  1. Trigger fires (manual button or scheduled time)
  2. Steps run in order, one after another
  3. Each step completes before the next starts
  4. Output from each step is captured
  5. Final results are saved and available for review

Passing Data Between Steps

Reference earlier step results:

Step 1: npm test (output: 5 passed, 2 failed)
Step 2: echo "Test results: {step-1-result}"
Step 3: AI analyzes "{step-2-result}"

Safety & Reliability

  • Automatic timeouts — Commands that hang get stopped automatically
  • Error tracking — See exactly what failed and why
  • Run history — Review past automation runs anytime
  • Easy debugging — Each step shows its output and any errors
  • Simple activation — Turn automations on/off without deleting them

Managing Your Automations

ActionHow to do it
View allGo to Automations view
Create newUse /automation slash command
EditClick Edit on any automation
Run nowClick Run manually button
Change scheduleEdit the automation details
View historySee all past runs and results
DeleteRemove automations you no longer need

Tips

  • Start simple — Begin with a single command, then add AI analysis
  • Chain results — Use outputs from one step as input to the next
  • Schedule wisely — Don't run automations too frequently (saves resources)
  • Test first — Run manually before setting up a schedule
  • Review results — Check automation run history to catch issues early