# swift/build

> Builds the package or Xcode scheme incrementally to report compiler errors.

Builds the package or Xcode scheme incrementally to report compiler errors.

Part of the [`swift`](/reference/configurations/swift/) configuration, at the `recommended` [level](/start/concepts/#levels). It runs at the `push` [stage](/start/concepts/#stage), once per scope. gspot runs this check itself. It needs a build of the project. It runs on macOS and Linux.

## Why

Swift checks types only during a build.

## What to do

Fix the first compiler error; later ones often come from the same mistake.

## Example

Assigning a string to an `Int` variable fails the build. Correct the value or the type.

## Turn it off

Turn it off for some files, with a reason:

```shell
gspot ignore swift/build --paths "<glob>" --reason "<why>"
```
