### Quick Start: List ADRs Source: https://github.com/zircote/git-adr/blob/main/docs/git-adr-skill.md Third step in the quick start guide: listing all available ADRs in the repository using the git-adr skill. ```bash 3. "What ADRs do we have?" → Claude runs: git adr list ``` -------------------------------- ### Quick Start: Initialize ADR Tracking Source: https://github.com/zircote/git-adr/blob/main/docs/git-adr-skill.md First step in the quick start guide: initializing ADR tracking in a repository using the git-adr skill. ```bash 1. "Initialize ADR tracking in this repo" → Claude runs: git adr init ``` -------------------------------- ### Start Interactive Onboarding Wizard Source: https://github.com/zircote/git-adr/blob/main/docs/COMMANDS.md Initiates an interactive wizard to guide users through the project's ADRs. Use this for new team members. ```bash git adr onboard ``` -------------------------------- ### Onboard to Project ADRs Source: https://github.com/zircote/git-adr/blob/main/skills/git-adr/references/workflows.md Get started with the project's ADRs by listing them or showing a specific ADR by its ID. ```bash git adr onboard or git adr list && git adr show ``` -------------------------------- ### Quick Start: Create an ADR Source: https://github.com/zircote/git-adr/blob/main/docs/git-adr-skill.md Second step in the quick start guide: creating a new ADR about a specific decision using the git-adr skill. ```bash 2. "Create an ADR about our decision to use TypeScript" → Claude creates a properly formatted ADR ``` -------------------------------- ### Manual Fish Completion Setup Source: https://github.com/zircote/git-adr/wiki/Shell-Completion Saves the git-adr completion script to the Fish completions directory. Alternatively, use automatic installation. ```fish git-adr completion fish > ~/.config/fish/completions/git-adr.fish ``` -------------------------------- ### Quick Start: Show Specific ADR Source: https://github.com/zircote/git-adr/blob/main/docs/git-adr-skill.md Fourth step in the quick start guide: showing the details of a specific ADR using its identifier with the git-adr skill. ```bash 4. "Show me the TypeScript decision" → Claude runs: git adr show 20251216-... ``` -------------------------------- ### Install git-adr with pip Source: https://github.com/zircote/git-adr/wiki/Getting-Started Standard installation using Python's package installer. ```bash pip install git-adr ``` -------------------------------- ### Install git-adr with uv Source: https://github.com/zircote/git-adr/wiki/Getting-Started Installation using the uv tool, a fast Python package manager. ```bash uv tool install git-adr ``` -------------------------------- ### User Skills Directory Structure Example Source: https://github.com/zircote/git-adr/blob/main/docs/spec/active/2025-12-15-git-adr-skill/ARCHITECTURE.md Shows the directory structure for the git-adr skill when installed in a user's local Claude skills directory. ```text ~/.claude/skills/ └── git-adr/ ├── SKILL.md └── references/ └── ... ``` -------------------------------- ### Example: Deployment Strategy Source: https://github.com/zircote/git-adr/blob/main/skills/git-adr/references/formats/y-statement.md An example Y-Statement detailing a deployment strategy decision for migrating a monolithic application. ```plaintext In the context of a monolithic application being migrated to microservices, facing the need for zero-downtime deployments with limited DevOps capacity, we decided to use blue-green deployments on Kubernetes, to achieve instant rollback capability and deployment confidence, accepting doubled infrastructure costs during deployment windows. ``` -------------------------------- ### Install Git Hooks During Initialization Source: https://github.com/zircote/git-adr/blob/main/docs/HOOKS_GUIDE.md Use these commands to install git-adr hooks when initializing the project. The interactive mode will prompt you, while the explicit option installs them directly. ```bash # Interactive setup prompts for hooks installation git adr init # Or explicitly install hooks during init git adr init --install-hooks ``` -------------------------------- ### Install git-adr with All Features Source: https://github.com/zircote/git-adr/blob/main/README.md Install git-adr with all available features enabled. Requires Cargo. ```bash cargo install git-adr --features all ``` -------------------------------- ### Install Git ADR with All Features using uv Source: https://github.com/zircote/git-adr/blob/main/docs/git-adr-product-brief.md Installs the git-adr tool with all features using the uv package manager. ```bash uv tool install "git-adr[all]" ``` -------------------------------- ### Homebrew Installation Commands Source: https://github.com/zircote/git-adr/blob/main/docs/spec/completed/2025-12-15-github-issues-13-14/ARCHITECTURE.md Commands to tap the custom repository and install the git-adr package using Homebrew. ```bash $ brew tap zircote/git-adr $ brew install git-adr ``` -------------------------------- ### Install git-adr with Wiki Support Source: https://github.com/zircote/git-adr/wiki/Wiki-Integration Install the git-adr package with optional wiki support. Use '[wiki]' for wiki-specific features or '[all]' for all available features. ```bash pip install "git-adr[wiki]" # Or with all features pip install "git-adr[all]" ``` -------------------------------- ### Install Git ADR with All Features Source: https://github.com/zircote/git-adr/blob/main/docs/git-adr-product-brief.md Installs the git-adr package with all available features using pipx. ```bash pipx install "git-adr[all]" ``` -------------------------------- ### Minimal Git-ADR Setup Source: https://github.com/zircote/git-adr/wiki/Configuration-Guide Initialize git-adr with default settings. The defaults are suitable for most use cases, providing a basic setup. ```bash git adr init # Defaults work for most cases ``` -------------------------------- ### Install git-adr Skill - Method 1: Copy from Repository Source: https://github.com/zircote/git-adr/blob/main/docs/git-adr-skill.md Instructions for installing the git-adr Claude Code skill by copying it directly from the repository. ```bash # Clone git-adr if you haven't already git clone https://github.com/zircote/git-adr.git cd git-adr # Copy skill to Claude Code skills directory cp -r skills/git-adr ~/.claude/skills/ ``` -------------------------------- ### Install Git Hooks Standalone Source: https://github.com/zircote/git-adr/blob/main/docs/HOOKS_GUIDE.md If git-adr is already initialized, use this command to install the pre-push hooks separately. ```bash git adr hooks install ``` -------------------------------- ### Install Git ADR for Development Source: https://github.com/zircote/git-adr/blob/main/docs/git-adr-product-brief.md Clones the git-adr repository and installs dependencies for development using uv. ```bash git clone https://github.com/epicpastures/git-adr cd git-adr uv sync --all-extras ``` -------------------------------- ### Install git-adr Skill - Method 2: Download from Release Source: https://github.com/zircote/git-adr/blob/main/docs/git-adr-skill.md Instructions for installing the git-adr Claude Code skill by downloading a release package. ```bash # Download the skill package from a release curl -LO https://github.com/zircote/git-adr/releases/download/vX.Y.Z/git-adr-X.Y.Z.skill # Extract to Claude Code skills directory unzip git-adr-X.Y.Z.skill -d ~/.claude/skills/ ``` -------------------------------- ### Error Handling: Git-ADR Not Installed Source: https://github.com/zircote/git-adr/blob/main/docs/spec/active/2025-12-15-git-adr-skill/ARCHITECTURE.md Provides guidance on what to do if the `git adr --version` command fails, including installation suggestions. ```text If `git adr --version` fails: → Provide installation instructions → Suggest: pip install git-adr → Or: brew tap zircote/git-adr && brew install git-adr ``` -------------------------------- ### Initialize Wiki Sync with Options Source: https://github.com/zircote/git-adr/wiki/Wiki-Integration Initialize wiki synchronization with explicit options for provider and repository. ```bash git adr wiki init [options] ``` ```bash # Auto-detect from origin remote git adr wiki init # Explicit GitHub setup git adr wiki init --provider github --repo myorg/myproject # GitLab setup git adr wiki init --provider gitlab --repo mygroup/myproject ``` -------------------------------- ### Install git-adr with Wiki Sync Features Source: https://github.com/zircote/git-adr/blob/main/README.md Install git-adr with the 'wiki' feature enabled for synchronization with GitHub/GitLab wikis. Requires Cargo. ```bash cargo install git-adr --features wiki ``` -------------------------------- ### Interactive Onboarding Wizard Source: https://github.com/zircote/git-adr/blob/main/docs/git-adr-product-brief.md Launches an interactive onboarding wizard for new team members to guide them through essential Architecture Decision Records. Use `--quick` for a brief summary or specify `--category` and `--role` for tailored paths. ```bash git adr onboard [--quick] [--category ] [--role ] ``` ```bash git adr onboard --status ``` ```bash git adr onboard --continue ``` -------------------------------- ### Interactive Onboarding Wizard Source: https://github.com/zircote/git-adr/blob/main/skills/git-adr/references/commands.md Launches an interactive wizard to guide users through onboarding, with options to filter ADRs. ```bash git adr onboard [OPTIONS] ``` -------------------------------- ### Onboard New Team Member Source: https://github.com/zircote/git-adr/blob/main/skills/git-adr/references/commands.md Guides on onboarding a new team member by using the interactive wizard, listing key decisions, and showing specific ADRs. ```bash git adr onboard git adr list --status accepted git adr show ``` -------------------------------- ### Setup and Build git-adr Source: https://github.com/zircote/git-adr/blob/main/README.md Clone the repository, build the project, and run tests. Includes commands for all features and linting. ```bash git clone https://github.com/zircote/git-adr.git cd git-adr # Build cargo build # Run tests cargo test # Run with all features cargo test --all-features # Check lints cargo clippy --all-targets --all-features # Format cargo fmt ``` -------------------------------- ### Documentation Structure: ADR_PRIMER.md Source: https://github.com/zircote/git-adr/blob/main/docs/spec/completed/2025-12-15-github-issues-13-14/ARCHITECTURE.md Presents the structure for ADR_PRIMER.md, explaining what Architecture Decision Records are, their importance, lifecycle, and how to get started with git-adr. ```markdown docs/ADR_PRIMER.md ├── What are Architecture Decision Records? ├── Why Document Decisions? │ ├── Onboarding new team members │ ├── Understanding historical context │ └── Preventing decision repetition ├── When to Write an ADR │ ├── Technology choices │ ├── Pattern selections │ └── Trade-off decisions ├── ADR Lifecycle │ ├── Proposed → Accepted │ ├── Accepted → Deprecated │ └── Accepted → Superseded ├── Common Mistakes │ ├── Too detailed │ ├── Too brief │ └── Not updating status ├── Getting Started with git-adr │ └── Quick 5-minute tutorial └── Further Reading └── Links to Nygard, MADR, etc. ``` -------------------------------- ### Set Up CI/CD and Templates Source: https://github.com/zircote/git-adr/blob/main/docs/COMMANDS.md Configures Continuous Integration/Continuous Deployment (CI/CD) for GitHub, generates all ADR templates, and installs git hooks. Use this after initializing a new project. ```bash # Set up CI/CD and templates git adr ci github git adr templates all git adr hooks install ``` -------------------------------- ### Viewing PowerShell Completion Script Source: https://github.com/zircote/git-adr/wiki/Shell-Completion Displays the PowerShell completion script generated by git-adr without installing it. This is useful for debugging or manual setup. ```powershell git-adr completion powershell ``` -------------------------------- ### Viewing Fish Completion Script Source: https://github.com/zircote/git-adr/wiki/Shell-Completion Displays the fish completion script generated by git-adr without installing it. This is useful for debugging or manual setup. ```fish git-adr completion fish ``` -------------------------------- ### Initialize Wiki Structure Source: https://github.com/zircote/git-adr/blob/main/docs/git-adr-product-brief.md Initializes the wiki structure by creating necessary directories and index templates. ```bash git adr wiki-init ``` -------------------------------- ### Viewing Zsh Completion Script Source: https://github.com/zircote/git-adr/wiki/Shell-Completion Displays the zsh completion script generated by git-adr without installing it. This is useful for debugging or manual setup. ```zsh git-adr completion zsh ``` -------------------------------- ### Viewing Bash Completion Script Source: https://github.com/zircote/git-adr/wiki/Shell-Completion Displays the bash completion script generated by git-adr without installing it. This is useful for debugging or manual setup. ```bash git-adr completion bash ``` -------------------------------- ### Build with Wiki Sync Features Source: https://github.com/zircote/git-adr/blob/main/docs/COMMANDS.md Enable wiki synchronization features by building with the '--features wiki' flag. ```bash # Build with wiki sync cargo build --release --features wiki ``` -------------------------------- ### Example Usage with Git Alias Source: https://github.com/zircote/git-adr/blob/main/docs/SHELL_COMPLETION.md Demonstrates common commands after setting up the 'git adr' alias. ```bash git adr new "My decision" git adr list git adr show ADR-0001 ``` -------------------------------- ### git-adr CLI Integration - AI Suggest Command Source: https://github.com/zircote/git-adr/blob/main/docs/spec/active/2025-12-16-git-adr-claude-skill/ARCHITECTURE.md Example of using the `git adr ai suggest` command to get AI-powered suggestions for an ADR. ```bash git adr ai suggest ``` -------------------------------- ### Build with All Features Source: https://github.com/zircote/git-adr/blob/main/docs/COMMANDS.md Compile the project with all available features enabled using the '--features all' flag. ```bash # Build with all features cargo build --release --features all ``` -------------------------------- ### Check Git ADR Initialization and Get Summary Source: https://github.com/zircote/git-adr/blob/main/skills/git-adr/workflows/session-start.md Execute these commands at session start to check if Git ADR is initialized and to retrieve a summary of ADRs if it is. Output is suppressed for silent execution. ```bash # Step 1: Check if initialized git notes --ref=adr list &>/dev/null && echo "INITIALIZED" || echo "NOT_INITIALIZED" # Step 2: If initialized, get summary git adr list --format oneline 2>/dev/null ``` -------------------------------- ### Configure Multi-Project Setup Source: https://github.com/zircote/git-adr/blob/main/docs/CONFIGURATION.md Demonstrates setting global git-adr preferences (editor, AI provider) and then overriding them for specific projects with different templates and sync settings. ```bash # Global settings (in ~/.gitconfig) git config --global adr.editor "code --wait" git config --global adr.ai.provider anthropic git config --global adr.ai.model claude-3-sonnet-20240229 # Project A: Formal decisions cd /path/to/project-a git adr config adr.template business git adr config adr.sync.auto_push true # Project B: Quick technical decisions cd /path/to/project-b git adr config adr.template nygard git adr config adr.sync.auto_push false ``` -------------------------------- ### Conceptual CI Gate and Build Job Dependency Source: https://github.com/zircote/git-adr/wiki/ADR-20251216-ci-gate-before-binary-builds-CI-Gate-Before-Binary-Builds This conceptual example illustrates how build jobs can declare a dependency on the 'ci-gate' job using 'needs: [ci-gate]'. This ensures that build jobs will not start until the 'ci-gate' job has completed successfully. ```yaml jobs: - ci-gate: runs ruff/black/mypy/pytest (on chosen canonical runner) - build (strategy.matrix: python-version, os): needs: [ci-gate]; proceeds only if ci-gate completed successfully ``` -------------------------------- ### Build with All Optional Features Source: https://github.com/zircote/git-adr/blob/main/RELEASING.md Compile the project with all optional features enabled, including AI, wiki sync, and extended export formats. ```bash cargo build --release --features all ``` -------------------------------- ### GitLab CI Pipeline Configuration for Git ADR Source: https://github.com/zircote/git-adr/blob/main/docs/SDLC_INTEGRATION.md This YAML configuration defines stages and jobs for validating and syncing Architecture Decision Records (ADRs) within a GitLab CI pipeline. It includes setup steps to download and install the git-adr binary. ```yaml stages: - validate - sync variables: GIT_STRATEGY: clone GIT_DEPTH: 0 .adr-setup: before_script: - curl -sSL https://github.com/zircote/git-adr/releases/latest/download/git-adr-x86_64-unknown-linux-gnu.tar.gz | tar xz - mv git-adr /usr/local/bin/ - git fetch origin 'refs/notes/*:refs/notes/*' || true adr-validate: extends: .adr-setup stage: validate rules: - if: $CI_PIPELINE_SOURCE == "merge_request_event" script: - git adr list - git adr stats adr-sync: extends: .adr-setup stage: sync rules: - if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH script: - git adr sync --push ``` -------------------------------- ### Configure Quick Decision Settings Source: https://github.com/zircote/git-adr/blob/main/skills/git-adr/references/configuration.md Set a template for quick decisions and adjust the AI temperature for less deterministic output. ```bash git adr config adr.template nygard git adr config adr.ai.temperature 0.3 ``` -------------------------------- ### Global Skill Installation Source: https://github.com/zircote/git-adr/blob/main/docs/spec/active/2025-12-16-git-adr-claude-skill/ARCHITECTURE.md Installs the git-adr skill globally in the ~/.claude/skills directory. This is the recommended installation path. ```bash cp -r skill-directory ~/.claude/skills/git-adr/ ``` -------------------------------- ### First Wiki Sync for GitHub Source: https://github.com/zircote/git-adr/wiki/Wiki-Integration Perform the initial wiki synchronization for a GitHub repository after setup. ```bash cd your-project git adr wiki init --provider github git adr wiki sync --push ``` -------------------------------- ### Install git-adr with AI Support Source: https://github.com/zircote/git-adr/wiki/AI-Features Install the AI extras for git-adr using pip. You can install just the AI features or all available features. ```bash pip install "git-adr[ai]" ``` ```bash # Or with all features pip install "git-adr[all]" ``` -------------------------------- ### New Project Initialization Source: https://github.com/zircote/git-adr/blob/main/skills/git-adr/references/workflows.md Initialize a new project with git-adr, create an initial ADR, and synchronize it to the remote repository. ```bash git adr init && git adr new "..." && git adr sync --push ``` -------------------------------- ### Install git-adr Core Source: https://github.com/zircote/git-adr/blob/main/docs/git-adr-product-brief.md Installs the core functionality of git-adr using pipx, the recommended method for Python CLI applications. This command installs only the essential features. ```bash pipx install git-adr ``` -------------------------------- ### Handling New Command in Main Source: https://github.com/zircote/git-adr/blob/main/CONTRIBUTING.md Illustrates how to handle the newly registered command in the `main.rs` file. This routes the command execution to the appropriate `run` function. ```rust Commands::MyCommand(args) => git_adr::cli::mycommand::run(args), ``` -------------------------------- ### Python CLI Integration for Hooks Install Source: https://github.com/zircote/git-adr/blob/main/docs/spec/completed/2025-12-15-git-hooks-sdlc-integration/ARCHITECTURE.md Integrates the 'hooks install' command into the main CLI application using Typer, with options for force and manual installation. ```python @app.command() def hooks_install( force: Annotated[bool, typer.Option("--force", "-f")] = False, manual: Annotated[bool, typer.Option("--manual")] = False, ) -> None: """Install git-adr hooks.""" from git_adr.commands.hooks_cli import run_hooks_install run_hooks_install(force=force, manual=manual) ``` -------------------------------- ### Initialize Wiki Sync Source: https://github.com/zircote/git-adr/wiki/Wiki-Integration Initialize wiki synchronization for your repository. The command can auto-detect the platform from the remote URL or accept explicit provider and repository arguments. ```bash # Auto-detect platform from remote URL git adr wiki init # Or specify explicitly git adr wiki init --provider github --repo owner/repo ``` -------------------------------- ### Local Build and Smoke Tests Source: https://github.com/zircote/git-adr/blob/main/RELEASING.md Build the release binary locally and run basic smoke tests, including version and help flag checks, core command execution, and test suite execution with all features. ```bash # Build and test locally car go build --release ./target/release/git-adr --version ./target/release/git-adr --help # Run test suite car go test --all-features ``` -------------------------------- ### Automatic Shell Completion Installation Source: https://github.com/zircote/git-adr/wiki/Shell-Completion Installs shell completion scripts automatically for Bash, Zsh, and Fish. After installation, restart your shell or source your config file. ```bash # Bash git-adr completion bash --install ``` ```bash # Zsh git-adr completion zsh --install ``` ```bash # Fish git-adr completion fish --install ``` -------------------------------- ### Install git-adr via Cargo Source: https://github.com/zircote/git-adr/blob/main/README.md Install git-adr using Cargo, Rust's package manager. This method is suitable for users with Rust and Cargo installed. ```bash cargo install git-adr ``` -------------------------------- ### Configure Multi-Project Setup Source: https://github.com/zircote/git-adr/blob/main/skills/git-adr/references/configuration.md Set global Git preferences and project-specific overrides for ADR editor and AI provider. ```bash # Global preferences git config --global adr.editor "code --wait" git config --global adr.ai.provider anthropic # Per-project overrides git adr config adr.template business # In formal project git adr config adr.template nygard # In quick project ``` -------------------------------- ### Error: git-adr Not Installed Source: https://github.com/zircote/git-adr/blob/main/skills/git-adr/workflows/session-start.md Instructions for installing the git-adr tool if it is not found. ```bash ⚠️ git-adr is not installed Install with: pip install git-adr # or brew tap zircote/git-adr && brew install git-adr ``` -------------------------------- ### Initialize Git-ADR for a New Project Source: https://github.com/zircote/git-adr/blob/main/skills/git-adr/references/workflows.md Set up ADR tracking in a new or existing git repository. This includes initializing git-adr, configuring a template, creating the first ADR, and pushing changes. ```bash # 1. Ensure you're in a git repository git rev-parse --is-inside-work-tree || git init # 2. Initialize ADR tracking git adr init # 3. Configure default template (optional) git adr config adr.template madr # 4. Create your first ADR documenting the ADR practice itself git adr new "Record architecture decisions" # 5. Push to remote to share with team git adr sync --push ``` -------------------------------- ### Multiple Shell Support Installation Source: https://github.com/zircote/git-adr/wiki/Shell-Completion Installs git-adr completions for multiple shells (Bash, Zsh, Fish) using the automatic installation method. This is useful for users who switch between different shells. ```bash # Install for all shells git-adr completion bash --install git-adr completion zsh --install git-adr completion fish --install ``` -------------------------------- ### Verify git-adr Installation Source: https://github.com/zircote/git-adr/wiki/Getting-Started Check if git-adr is installed correctly by running the version command. ```bash git-adr --version # or git adr --version ``` -------------------------------- ### Initialize Wiki Source: https://github.com/zircote/git-adr/wiki/Wiki-Integration Check if the wiki is enabled in repository settings and then re-initialize it. This command is used when encountering a 'Wiki not found' error. ```bash # Check wiki is enabled in repository settings # Then re-initialize git adr wiki init --provider github ``` -------------------------------- ### Install Last Python Release Source: https://github.com/zircote/git-adr/blob/main/RELEASING.md Installs the last Python release of the git-adr project. ```bash pip install git-adr==0.3.0 ``` -------------------------------- ### Generate Onboarding Summary with Git-ADR Source: https://github.com/zircote/git-adr/blob/main/skills/git-adr/references/workflows.md Create a summary of architectural decisions for new team members. This command can be focused on specific topics to provide relevant information. ```bash # Generate onboarding summary git adr onboard # Focus on specific topics git adr onboard --topic database git adr onboard --topic authentication ``` -------------------------------- ### Fish Shell Completion Setup Source: https://github.com/zircote/git-adr/wiki/Shell-Completion Completions for Fish shell are file-based and should be placed in `~/.config/fish/completions/`. The directory will be created if it doesn't exist. ```shell # Example: Assuming 'your_script' is the command # Place completion file in ~/.config/fish/completions/your_script.fish ``` -------------------------------- ### Custom ADR Template Example Source: https://github.com/zircote/git-adr/blob/main/docs/ADR_FORMATS.md An example of a custom ADR template file using markdown. ```markdown # {title} ## Status {status} ## Your Custom Section ``` -------------------------------- ### Run Onboarding Non-Interactively Source: https://github.com/zircote/git-adr/blob/main/docs/COMMANDS.md Runs the onboarding process without interactive prompts. Use this for automated setups or quick overviews. ```bash git adr onboard --non-interactive ``` -------------------------------- ### Commit Pointer Comment Example Source: https://github.com/zircote/git-adr/blob/main/docs/git-adr-product-brief.md Example of a brief pointer comment added to a commit when wiki.commit-pointers is enabled. ```markdown 📋 **Related ADR:** [Use PostgreSQL for Persistence](../../wiki/architecture-decisions/20251214-use-postgresql) Status: `accepted` | [View full decision →](../../wiki/architecture-decisions/20251214-use-postgresql) ``` -------------------------------- ### Initialize Wiki Integration Source: https://github.com/zircote/git-adr/blob/main/docs/git-adr-product-brief.md Command to initialize the git-adr wiki integration by auto-detecting the wiki URL from the repository origin. ```bash # Auto-detect wiki URL from origin (works for GitHub/GitLab) git adr wiki-init ```