Skip to content

API Reference

This reference provides comprehensive documentation for all agent-init commands, configuration options, and templates.

The Makefile provides automation for common development tasks. All commands should be run from the project root.

Starts the development environment.

Usage:

Terminal window
make dev

Environment Variables:

  • PORT: Server port (default: 3000)
  • ENV: Environment mode (default: development)

Builds the project for production.

Usage:

Terminal window
make build

Options:

  • TARGET: Build target (default: dist)
  • MINIFY: Enable minification (default: true)

Runs the test suite.

Usage:

Terminal window
make test [ARGS]

Arguments:

  • ARGS: Additional test runner arguments
  • --coverage: Generate coverage report
  • --watch: Run tests in watch mode

Runs code quality checks.

Usage:

Terminal window
make lint

Checks:

  • Code formatting
  • Type checking (if applicable)
  • Style guide compliance

Begins a new development session.

Usage:

Terminal window
make session-start

Actions:

  1. Creates session entry in CLAUDE.md
  2. Prompts for session goals
  3. Initializes development environment
  4. Creates session branch (optional)

Ends the current development session.

Usage:

Terminal window
make session-end

Actions:

  1. Updates session tracking
  2. Runs quality checks
  3. Creates session summary
  4. Commits session notes

Prepares changelog for a new release.

Usage:

Terminal window
make changelog-prepare VERSION=x.y.z

Parameters:

  • VERSION: Target version number (required)

Example:

Terminal window
make changelog-prepare VERSION=1.2.0

Finalizes changelog for release.

Usage:

Terminal window
make changelog-release

Actions:

  1. Updates version in CHANGELOG.md
  2. Sets release date
  3. Creates git tag
  4. Commits changes

Creates a new GitHub issue.

Usage:

Terminal window
make issue

Interactive prompts for:

  • Issue title
  • Issue type (bug, feature, chore)
  • Description
  • Labels

Creates a pull request.

Usage:

Terminal window
make pr

Requirements:

  • Clean working directory
  • Current branch != main
  • All tests passing

The CLAUDE.md file uses the following structure:

# Project Name
## Overview
[Project description and context]
## Current Session
- **Date**: YYYY-MM-DD
- **Goals**:
- [ ] Goal 1
- [ ] Goal 2
- **Branch**: feature/description
## Session History
[Previous sessions documentation]
## Issues
- [ ] #123: Issue description
- [x] #122: Completed issue
## Key Decisions
[Architecture and design decisions]
## External Repositories
[Git submodules documentation]

Standard patterns included:

# Dependencies
node_modules/
vendor/
external/*/
# Build outputs
dist/
build/
*.o
*.so
# IDE files
.vscode/
.idea/
*.swp
# Environment
.env
.env.local
# OS files
.DS_Store
Thumbs.db
# Logs
*.log
logs/
# Testing
coverage/
.coverage

Common variables you can override:

# Development
PORT ?= 3000
ENV ?= development
# Build
BUILD_DIR ?= dist
SOURCE_DIR ?= src
# Testing
TEST_DIR ?= tests
COVERAGE_DIR ?= coverage
# Tools
PYTHON ?= python3
NODE ?= node
## Description
[Clear description of the issue]
## Expected Behavior
[What should happen]
## Current Behavior
[What actually happens]
## Steps to Reproduce
1. Step one
2. Step two
3. Step three
## Environment
- OS: [e.g., macOS 12.0]
- Version: [e.g., 1.0.0]
## Description
[Summary of changes]
## Related Issues
Fixes #123
## Type of Change
- [ ] Bug fix
- [ ] New feature
- [ ] Breaking change
- [ ] Documentation update
## Testing
- [ ] Unit tests pass
- [ ] Integration tests pass
- [ ] Manual testing completed
## Checklist
- [ ] Code follows style guidelines
- [ ] Self-review completed
- [ ] Documentation updated
- [ ] Tests added/updated
VariableDescriptionDefault
PROJECT_NAMEProject identifier(required)
GIT_REMOTEGit remote URL(required)
VariableDescriptionDefault
CLAUDE_SESSIONCurrent session ID(auto-generated)
DEBUGEnable debug outputfalse
CIContinuous integration modefalse
COVERAGE_THRESHOLDMinimum test coverage80
CodeDescriptionResolution
1General errorCheck error message
2Missing dependencyInstall required tools
3Test failureFix failing tests
4Lint errorFix code style issues
5Build failureCheck build configuration
10Git errorCheck git status
11No active sessionRun make session-start
12Uncommitted changesCommit or stash changes

Create custom pre/post hooks for commands:

.make/hooks.mk
pre-test:
@echo "Running pre-test setup..."
post-build:
@echo "Running post-build cleanup..."

Add project-specific commands:

# Custom command
.PHONY: deploy
deploy: build test
@echo "Deploying to production..."
# Your deployment logic