> ## Documentation Index
> Fetch the complete documentation index at: /docs/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> Bach builds Windows installers from one bach.toml with the bach command: bach init, bach check, bach preview, bach build. Installs are per user and need no administrator rights by default. installer.scope = "machine" installs for every user after one Windows prompt. On Windows, run setup files with Start-Process -Wait -PassThru in PowerShell, and give signtool arguments that start with the word sign.

# [arch.arm64]

> One download for x64 and ARM64: build an ARM64 setup file next to the x64 one and list both in the update feed; the online installer picks the right one.

The main build packs `files.source` with the x64 setup runtime. `[arch.arm64]` names the ARM64 build of the same app, and `bach build` then also writes an ARM64 setup file, built on the ARM64 runtime, and lists both in the update feed.

```toml bach.toml theme={"theme":{"light":"github-light","dark":"github-dark"}}
[files]
source = "build/x64"

[arch.arm64]
source = "build/arm64"                   # the ARM64 build of the app's files
exclude = ["*.pdb"]                      # optional: files.exclude for this folder
runtime = "tools/arm64/bach-setup.exe"   # optional: or --runtime-arm64 / BACH_RUNTIME_ARM64
```

```bash theme={"theme":{"light":"github-light","dark":"github-dark"}}
bach build --runtime-arm64 path/to/arm64/bach-setup.exe
```

| Setting | Meaning |
| - | - |
| `source` | The folder with the ARM64 files. Required. |
| `exclude` | `files.exclude` for this folder; the main one applies when left out. |
| `runtime` | The ARM64 `bach-setup.exe`, relative to `bach.toml`. |

* The ARM64 runtime is in every release's `bach-<version>-windows-arm64.zip`. Bach checks that it is an ARM64 program and refuses an x64 one. `--x64-only` builds only the x64 file.
* Both setup files carry the same app id and version. The ARM64 file is named `Hello-Setup-1.4.0-arm64.exe`.
* `latest.json` keeps the x64 file as its main entry and adds `arch.arm64` with its own link, SHA-256, size and, with `[updates] public_key`, its own signature. Older apps ignore it and keep taking the x64 file.
* The online installer is built once and asks Windows what the computer is, so on Windows on ARM it downloads the ARM64 file. An installed app updates with the architecture it was installed with.
* `bach feed SETUP.exe --arm64 SETUP-arm64.exe` writes the feed with the ARM64 listing when you build the files separately.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.