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

# [[context_menu]]: right-click entries

> Add Explorer right-click entries for files, folders, folder backgrounds or file types that open your app, with every setting and Windows 11 notes.

`[[context_menu]]` adds an entry to File Explorer's right-click menu that starts your app with the clicked item. For example, a notes app might add **Add to Hello Notes** for text files.

```toml bach.toml theme={"theme":{"light":"github-light","dark":"github-dark"}}
[[context_menu]]
name = "Add to Hello Notes"
on = [".txt", ".md"]

[[context_menu]]
name = "Open Hello Notes here"
on = "background"
```

| Setting | Required | Meaning |
| - | - | - |
| `name` | yes | The menu text, 1 to 80 characters with at least one letter or digit |
| `on` | yes | Where it appears: one value or a list |
| `arguments` | no | Command line after your program. Default `"%1"` (the clicked item), or `"%V"` (the folder) for `background`. |

| `on` value | Appears on |
| - | - |
| `"files"` | every file |
| `"folders"` | every folder |
| `"background"` | the empty space inside a folder |
| `".md"` | files with that extension (not types that run code) |

## Behavior

* On Windows 11 the entry appears under **Show more options**.
* With several files selected, your app starts once per file.
* Entries are written under `Software\Classes` for the user (or the computer for a machine-wide install), with a `BachApp` mark. Only marked entries are changed or removed.
* Two names that differ only in punctuation would use the same key and are refused.
* `bach inspect` shows them as `Right-click`.

Windows only.


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