Statusline setup breaks Alacritty config when keyboard.bindings uses inline array syntax

Resolved 💬 2 comments Opened Mar 8, 2026 by dhh Closed Apr 5, 2026

Bug

Claude Code's statusline setup appends a [[keyboard.bindings]] block to ~/.config/alacritty/alacritty.toml to configure Shift+Enter for multiline input. However, if keyboard.bindings is already defined using TOML inline array syntax, this causes a parse error because TOML doesn't allow mixing inline array syntax with array-of-tables syntax for the same key.

Steps to reproduce

  1. Have an existing Alacritty config with inline array bindings:
[keyboard]
bindings = [
{ key = "Insert", mods = "Shift", action = "Paste" },
{ key = "Insert", mods = "Control", action = "Copy" }
]
  1. Let Claude Code's statusline setup append its Shift+Enter binding
  1. The config becomes:
[keyboard]
bindings = [
{ key = "Insert", mods = "Shift", action = "Paste" },
{ key = "Insert", mods = "Control", action = "Copy" }
]

[[keyboard.bindings]]
key = "Return"
mods = "Shift"
chars = "\^[\r"
  1. Alacritty fails to load with:
Config error: TOML parse error at line 26, column 12
duplicate key

Expected behavior

The statusline setup should detect the existing keyboard.bindings format and either:

  • Append the new binding into the existing inline array, or
  • Convert to a consistent format before adding

Environment

  • Alacritty on Linux (Arch)
  • Claude Code CLI

View original on GitHub ↗

This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗