> ## Documentation Index
> Fetch the complete documentation index at: https://www.towbar.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Sync and automation

> Understand Git reconciliation, manual syncs, and when a sync becomes a deployment.

A sync validates an immutable repository commit and updates Towbar's inventory. It is distinct from a deployment. Initial connection, branch changes, and **Sync now** import configuration without starting workloads.

## Review a sync

Open a Repository's **Environments** page and inspect the latest sync for its commit, outcome, and issues. A successful sync can add or update apps and resources, archive removed IDs, and update notification subscriptions. Invalid configuration fails atomically; the last valid configuration remains active.

Pushes to a mapped branch start reconciliation through the source-control webhook. Use **Sync now** when you need to inspect the current branch state immediately. If no update arrives, check the integration's repository access and webhook delivery before retrying.

## Enable automatic deployment deliberately

Auto-deploy is opt-in on each workload. For an app, limit triggering changes to files that can affect its build:

```yaml title=".towbar/apps/web.app.yml" theme={"system"}
id: web
name: Web
autoDeploy:
  inputs:
    - package.json
    - pnpm-lock.yaml
    - apps/web/**
```

The paths are relative to the repository root. Include shared packages and build files, not only the app directory. The Repository's automation controls can pause automatic work during maintenance; manual deployment remains a separate action. A manifest change can therefore sync successfully without changing the running release.

See [Deployments and releases](/docs/deployments) for queueing and promotion, and [environment branches](/docs/repositories/environments) for branch changes.
