Skip to content

Commit 8dceeec

Browse files
GordonBeemingclaudegitbutler-client
authored
fix: convert daily cost from USD to local currency (#4)
goccc returns total_cost in USD but was displayed with local currency symbol without conversion, causing daily cost to appear lower than session cost. Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com> Co-authored-by: GitButler <gitbutler@gitbutler.com>
1 parent d6e7af6 commit 8dceeec

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

statusline.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,8 @@ fi
147147
# --- Daily cost ---
148148
daily_cost_display=""
149149
if [[ "$daily_cost" != "0" && "$daily_cost" != "null" ]]; then
150-
daily_cost_display="💰 $(format_cost "$daily_cost") today"
150+
daily_cost_val=$(echo "$daily_cost $currency_rate" | awk '{printf "%.2f", $1 * $2}')
151+
daily_cost_display="💰 $(format_cost "$daily_cost_val") today"
151152
fi
152153

153154
# --- Rate limit bar ---

0 commit comments

Comments
 (0)