# Worktree file includes

> Link ignored local configuration into every new Zuse worktree.

Canonical URL: https://docs.zuse.sh/projects/file-includes



Dependencies and secrets are often intentionally absent from Git. `file_include_globs` links matching files from the main checkout into each new Zuse worktree at the same relative path.

```toml
file_include_globs = [
  ".env",
  ".env.local",
  "apps/web/.env.local",
]
```

## Behavior [#behavior]

* Patterns are resolved from the project's main checkout.
* Matching files appear at the same relative path in a newly created worktree.
* Existing destination files are left untouched.
* Links continue to refer to the source file, so edits affect the shared local configuration.
* Missing optional patterns do not need placeholder files.

Use narrow patterns. Linking `.env*` can unintentionally make production or unrelated environment files available to every worktree and agent.

## Legacy projects [#legacy-projects]

A root `.worktreeinclude` file may still be read for compatibility. New configuration belongs in `.zuse/settings.toml`, where it can be validated alongside the rest of the repository settings.
