# Converting Existing Repos

```bash
wt init [--dry-run] [-y]
```

Converts a standard git repository to bare worktree structure.

## Options

| Flag | Purpose |
|------|---------|
| `--dry-run` | Show what would happen without making changes |
| `-y` | Skip confirmation prompt |

## What It Does

1. Moves `.git/` to `.bare/`
2. Creates `.git` file pointing to `.bare/`
3. Creates worktree for current branch
4. Copies untracked/ignored files to worktree (preserves `.env`, build artifacts, etc.)
5. Removes orphaned files from project root

## Example

```bash
cd ~/repos/existing-project
wt init --dry-run    # preview changes
wt init -y           # convert without prompting
```

After conversion:

```
existing-project/
├── .bare/           # was .git/
├── .git             # file pointing to .bare/
└── main/            # worktree with your files
```
