> ## 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.

# Quickstart: build your first Bach installer

> Install the bach command, write a minimal bach.toml, preview the window and build a Setup.exe for your Windows app in about five minutes.

This quickstart takes you from an app on your disk to a `Setup.exe` you can share. It needs the `bach` command, a folder that holds your built app, and about five minutes.

**1. Install Bach**

You do not need Rust, and nothing asks for administrator rights. With Node.js 18 or newer, on Windows, macOS or Linux:

```bash theme={"theme":{"light":"github-light","dark":"github-dark"}}
npm install --global @usebach/cli
```

Then check the install:

```bash theme={"theme":{"light":"github-light","dark":"github-dark"}}
bach doctor
```

No Node.js? In PowerShell, one line installs `bach.exe` and `bach-setup.exe` to `%LOCALAPPDATA%\Programs\bach-cli` and adds that folder to your `PATH` (open a new terminal afterwards):

```powershell theme={"theme":{"light":"github-light","dark":"github-dark"}}
irm https://raw.githubusercontent.com/usebach/bach/main/install.ps1 | iex
```

For macOS or Linux without Node.js, a zip download or a Scoop install, see [Install Bach](/docs/installation.md).

**2. Build your app into one folder**

Bach installs the contents of one folder. Build or copy your app into it, with the `.exe` and everything it needs next to it: DLLs, assets, data files.

```text theme={"theme":{"light":"github-light","dark":"github-dark"}}
my-app/
  bach.toml
  build/
    my-app.exe
    resources/
```

See [Prepare your app](/docs/guides/prepare-your-app.md) for typical folders per stack.

**3. Write bach.toml**

In your project folder, run:

```bash theme={"theme":{"light":"github-light","dark":"github-dark"}}
bach init
```

In a Rust, Tauri, Electron or .NET project, `bach init` fills in the name, version, publisher, program and build folder from the project's own files. Otherwise it writes placeholders for you to edit. Only two sections are required:

```toml bach.toml theme={"theme":{"light":"github-light","dark":"github-dark"}}
[app]
name = "My App"            # shown in the window, the Start menu and Settings › Apps
version = "1.0.0"
publisher = "Your Name"
executable = "my-app.exe"  # the program to start, inside the files folder

[files]
source = "build"           # everything in this folder is installed
```

**4. Check the config**

```bash theme={"theme":{"light":"github-light","dark":"github-dark"}}
bach check
```

`bach check` lists every file the installer will install, or tells you in one sentence what is wrong, naming the setting at fault.

**5. Preview the window**

```bash theme={"theme":{"light":"github-light","dark":"github-dark"}}
bach preview
```

This opens the real installer window with every step pretended. Nothing is installed. Add `--uninstall` to see the removal window, `--theme dark` for dark mode and `--lang de` for another language. Preview needs Windows.

**6. Build**

```bash theme={"theme":{"light":"github-light","dark":"github-dark"}}
bach build
```

The setup file lands in `dist\My App-Setup-1.0.0.exe` by default. Run it to try the real thing, then remove the app again from **Settings › Apps**.

> [!TIP]
>
> You now have a single `Setup.exe` that installs your app for the current user, adds a Start menu shortcut and registers an uninstaller.

## Make it yours

All of these are optional:

```toml bach.toml theme={"theme":{"light":"github-light","dark":"github-dark"}}
[app]
description = "Your notes, everywhere."  # the line under the heading
icon = "assets/app.ico"                  # the setup file's icon, and the logo if it has a PNG inside

[installer]
logo = "assets/logo.svg"   # or a .png, or "none"
accent = "#2563eb"         # buttons, the progress bar, ticked boxes
theme = "system"           # or "light" / "dark"
languages = ["en", "de"]   # leave out to speak all 13, following Windows
license = "LICENSE.txt"    # an accept page before installing
start_with_windows = false # offered, unticked
add_to_path = "always"     # for command-line tools

[text]
footer = "Made with care by {publisher}"

[uninstall]
data = ['%APPDATA%\My App']
data_description = "Your settings and saved projects."
```

## Release from GitHub with one click

In a GitHub repository, `bach init` also wrote `.github/workflows/bach-release.yml` (`bach workflow` adds it to an existing project). Commit and push it, then press **Actions › Release › Run workflow**. It raises the version in every file that has one, builds your app and the setup file, and publishes a release that installed apps update from. See [One-click releases](/docs/guides/releasing.md).

## Ship an update by hand

Raise `version` in `bach.toml`, rebuild, and hand out the new setup file. Running it over an install updates it in place: it keeps the folder and the user's choices, and removes files the new version no longer ships. If anything goes wrong midway, the earlier version stays exactly as it was.

> [!WARNING]
>
> Keep `[app] id` (it defaults to the name) the same across versions. It is how Bach recognises an existing install, and changing it makes updates install side by side.

## Next steps

> [card] [Customize the window](/docs/guides/customize-the-window.md)
>
> Logo, accent, theme, languages, license and every text.

> [card] [Sign your setup file](/docs/guides/signing.md)
>
> Reduce SmartScreen warnings with a code-signing certificate.

> [card] [Updates](/docs/guides/updates.md)
>
> Update over older installs, or let the installed app update itself.

> [card] [Automate in CI](/docs/guides/ci.md)
>
> Build the setup file with the GitHub Action or any pipeline.


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