---
title: Migrating from Pint
description: Move a project from Pint to Pun in three steps.
---

Start with a clean Git tree, and keep Pint around until you've compared the two.

1. **Convert the config**

    ```bash
    pun migrate --from pint --dry-run   # see what it would write
    pun migrate --from pint
    ```

    This writes `pun.toml`. If a rule isn't supported yet, Pun tells you and skips it.

2. **Compare**

    ```bash
    vendor/bin/pint
    pun check --fix
    vendor/bin/pint --test
    pun check
    git diff
    ```

    Both checks should pass and the diff should be empty. If not, look at what's different before you switch. `pun check` may also find lint and analyse problems Pint never looked for. That's expected.

3. **Update scripts and CI**

    ```json composer.json
    {
    	"scripts": {
    		"lint": "pun check --fix",
    		"test:lint": "pun check"
    	}
    }
    ```

    In CI, swap `vendor/bin/pint --test` for `pun check`. See [CI](/docs/guides/ci).

## Good to know

- Pint's risky fixers are lint rules in Pun. So use `pun check --fix`, not just `pun format`, to get everything your Pint config did.
- The [Pint mapping](/docs/migrate/from/pint) shows where each Pint rule went.
- `--ansi` and `--no-ansi` are `--color=always` and `--color=never`. `--bail`, `--cache-file` and the `txt` and `xml` formats aren't supported.

## Done with Pint?

```bash
pun remove laravel/pint
rm pint.json
```

Changed your mind? Put your old scripts and CI back. Migration never deletes `pint.json`.
