---
title: Why three commands
description: What pun format, pun lint, and pun analyse each do, and the order pun check runs them in.
---

Each command does one job. [`pun check`](/docs/commands/check) runs all three.

- **`pun format`** changes layout, casing, and spelling only. It never changes what the code does, so you can run it on save. Risky fixers that change behaviour, such as rewriting `==` to `===`, are lint rules like [`types/no-loose-comparison`](/docs/rules/lint/types/no-loose-comparison).
- **`pun lint`** reports problems in a file, and `--fix` fixes many of them. Upgrades, such as newer PHP syntax, come as lint sets like [`modernize`](/docs/rules/sets/modernize).
- **`pun analyse`** checks types across files, like PHPStan, and never edits files. Each finding has an identifier such as `argument.type`.

`pun check --fix` applies lint fixes, formats the result, and then analyses the final code. It reports only what is left.
