Skip to main content
[[registry]] writes registry values when the app is installed, for apps that read their install folder or a setting from the registry. Each section is one value. The values go to HKCU for a per-user install and to HKLM for a machine-wide install.
bach.toml

32-bit programs

A 32-bit program that reads HKLM\Software\Vendor is sent by Windows to HKLM\Software\WOW6432Node\Vendor. A machine-wide app (installer.scope = "machine") whose program is 32-bit therefore needs view = "32" on the values it reads, or "both" when it ships 32-bit and 64-bit programs. Writing, updating and removing use the same view, and "both" handles both. You cannot name WOW6432Node yourself, because that key is refused. HKCU\Software is not redirected, so the setting rarely matters in a per-user install.
bach.toml
bach check and bach build warn when the install is machine-wide, app.executable is a 32-bit program (its PE header says x86) and a [[registry]] value leaves view out.

What setup does

  • An update writes the values again and removes the ones the new version no longer lists.
  • Removing the app deletes a value only while it still holds exactly what setup wrote. A value that the user or the app changed since stays. Keys that end up empty are removed too, but never Software itself.
  • Keys that belong to Windows, other programs or Bach are refused: Software\Classes, Software\Policies, Software\Wow6432Node, Software\Bach, and every key of the vendors Microsoft, Google, Mozilla, Mozillaplugins, Chromium, RegisteredApplications, Clients and ODBC. Those hold Office trusted locations, Defender exclusions, certificates, browser extension hooks and the like. bach check also warns when the key is not below a folder named after app.publisher, app.name or app.id, which usually means a typo. Use [[protocols]] and [[file_types]] and [[context_menu]] for what those keys are for.
  • A value can be at most 4096 characters, and the same key and name can be set only once.
  • bach inspect lists each value as Registry.