CLI

warden

warden [target] [options]

Run code analysis on the specified target. If no target is given, analyzes uncommitted changes.

warden                     # Analyze uncommitted changes (default)
warden src/auth.ts         # Analyze specific file
warden src/api/            # Analyze a directory
warden HEAD~3..HEAD        # Analyze changes in a git range

warden init

warden init [options]

Initialize Warden in your project. Creates a configuration file and GitHub workflow.

warden init            # Interactive setup
warden init --force    # Overwrite existing files

warden add

warden add [skill-name] [options]

Add a skill trigger to your configuration. Run without arguments for interactive mode.

warden add                     # Interactive mode
warden add security-review     # Add local skill
warden add --list              # List available skills

# Remote skills from GitHub repositories
warden add --remote getsentry/warden-skills --skill security-review
warden add --remote getsentry/warden-skills@abc123 --skill api-review  # Pinned to commit

warden sync

warden sync [remote]

Update cached remote skills. Refreshes unpinned skills to their latest versions.

warden sync                    # Update all remote skills
warden sync getsentry/warden-skills  # Update specific remote

warden setup-app

warden setup-app [options]

Create a GitHub App for Warden. This gives you a custom bot identity instead of the generic "github-actions" user.

warden setup-app               # For a personal account
warden setup-app --org my-org  # For an organization

Global Options

Skill References

The --skill option accepts multiple formats:

# By name (resolved from .warden/skills/, .agents/skills/, .claude/skills/)
warden --skill security-review

# Relative path
warden --skill ./skills/custom-review

# Absolute path
warden --skill /shared/skills/company-review

# Home directory expansion
warden --skill ~/my-skills/security

Resolution order:

  1. Remote repository (if remote is specified in trigger config)
  2. Direct path (if contains /, \, or starts with .)
  3. Conventional directories: .warden/skills/, .agents/skills/, .claude/skills/

Environment Variables

WARDEN_ANTHROPIC_API_KEY
Anthropic API key. Required for CI/CD. For local use, Warden can use your Claude Code subscription instead (run claude login).
ANTHROPIC_API_KEY
Fallback if WARDEN_ANTHROPIC_API_KEY is not set
WARDEN_SKILL_CACHE_TTL
Cache duration for unpinned remote skills. Default: 24h