From 03f7420d7213435e46b18e69d268c7d052114594 Mon Sep 17 00:00:00 2001 From: David Heinemeier Hansson Date: Thu, 2 Jul 2026 22:14:33 -0700 Subject: [PATCH] Pass empty placement explicitly in bar replace cmd_replace fed $PLACEMENT_FROM_SECTION/$PLACEMENT_FROM_INDEX to jq without ever calling parse_placement, so they were always empty strings that implied flag support which does not exist. Pass literal empties with a comment stating replace resolves by widget id only. Co-Authored-By: Claude Fable 5 --- bin/omarchy-bar | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/bin/omarchy-bar b/bin/omarchy-bar index 261dbf21..820bff9a 100755 --- a/bin/omarchy-bar +++ b/bin/omarchy-bar @@ -756,11 +756,13 @@ cmd_replace() { | .bar.layout[\$source.section][\$source.index].id = \$new JQ ) + # resolve_source finds by widget id when no placement is given; replace + # takes no placement flags, so pass empty placement explicitly. commit "$prog" \ --arg widgetId "$old" \ --arg new "$new" \ - --arg fromSection "$PLACEMENT_FROM_SECTION" \ - --arg fromIndex "$PLACEMENT_FROM_INDEX" + --arg fromSection "" \ + --arg fromIndex "" echo "Replaced $old with $new" }