@owloops/claude-powerline 1.23.4 → 1.24.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +249 -49
- package/dist/index.mjs +12 -11
- package/package.json +1 -1
- package/plugin/bin/preview.sh +104 -4
- package/plugin/commands/powerline.md +78 -8
- package/plugin/templates/config-tui-compact.json +59 -0
- package/plugin/templates/config-tui-full.json +110 -0
- package/plugin/templates/config-tui-standard.json +70 -0
package/plugin/bin/preview.sh
CHANGED
|
@@ -6,7 +6,50 @@ SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
|
|
6
6
|
readonly SCRIPT_DIR
|
|
7
7
|
readonly PLUGIN_ROOT="${SCRIPT_DIR}/.."
|
|
8
8
|
|
|
9
|
-
readonly SAMPLE_JSON='{"model":{"id":"claude-sonnet-4-20250514","display_name":"Sonnet 4"},"cost":{"total_cost_usd":0.42,"message_cost_usd":0.03,"duration":"15m"},"context_window":{"context_window_size":200000,"used_percentage":35,"current_usage":{"input_tokens":50000,"cache_creation_input_tokens":10000,"cache_read_input_tokens":5000}},"cwd":"/home/user/my-project","workspace":{"current_dir":"/home/user/my-project"},"
|
|
9
|
+
readonly SAMPLE_JSON='{"model":{"id":"claude-sonnet-4-20250514","display_name":"Sonnet 4"},"cost":{"total_cost_usd":0.42,"message_cost_usd":0.03,"duration":"15m"},"context_window":{"context_window_size":200000,"used_percentage":35,"current_usage":{"input_tokens":50000,"cache_creation_input_tokens":10000,"cache_read_input_tokens":5000}},"cwd":"/home/user/my-project","workspace":{"current_dir":"/home/user/my-project"},"session_id":"abc123"}'
|
|
10
|
+
|
|
11
|
+
setup_tui_transcript() {
|
|
12
|
+
local now_iso user_iso cwd_encoded transcript_dir
|
|
13
|
+
now_iso=$(date -u +"%Y-%m-%dT%H:%M:%S.000Z")
|
|
14
|
+
user_iso=$(date -u -d "-13 seconds" +"%Y-%m-%dT%H:%M:%S.000Z" 2>/dev/null \
|
|
15
|
+
|| date -u -v-13S +"%Y-%m-%dT%H:%M:%S.000Z" 2>/dev/null \
|
|
16
|
+
|| echo "${now_iso}")
|
|
17
|
+
|
|
18
|
+
# Encode the preview CWD the same way Claude Code encodes project dirs
|
|
19
|
+
# On Windows: C:\Users\foo\proj -> C--Users-foo-proj
|
|
20
|
+
# On Unix: /home/user/proj -> -home-user-proj
|
|
21
|
+
local preview_cwd
|
|
22
|
+
# Create a temp git repo so previews always show git data
|
|
23
|
+
local fake_repo
|
|
24
|
+
fake_repo="$(mktemp -d)/my-project"
|
|
25
|
+
mkdir -p "${fake_repo}"
|
|
26
|
+
git -C "${fake_repo}" init -b main --quiet 2>/dev/null
|
|
27
|
+
git -C "${fake_repo}" -c user.name="User" -c user.email="u@e.co" commit --allow-empty -m "init" --quiet 2>/dev/null
|
|
28
|
+
git -C "${fake_repo}" checkout -b feat/my-feature --quiet 2>/dev/null
|
|
29
|
+
touch "${fake_repo}/newfile.txt"
|
|
30
|
+
printf 'change\n' > "${fake_repo}/README.md"
|
|
31
|
+
git -C "${fake_repo}" add README.md 2>/dev/null
|
|
32
|
+
|
|
33
|
+
# Use native path for Node.js compatibility (Windows needs C:\... not /c/...)
|
|
34
|
+
preview_cwd="$(cd "${fake_repo}" && pwd -W 2>/dev/null || pwd)"
|
|
35
|
+
cwd_encoded="$(printf '%s' "${preview_cwd}" | sed 's|[/\\]|-|g; s|:||g')"
|
|
36
|
+
TUI_PREVIEW_CWD="${preview_cwd}"
|
|
37
|
+
|
|
38
|
+
transcript_dir="${HOME}/.claude/projects/${cwd_encoded}"
|
|
39
|
+
TUI_TRANSCRIPT="${transcript_dir}/preview-123.jsonl"
|
|
40
|
+
mkdir -p "${transcript_dir}"
|
|
41
|
+
printf '{"timestamp":"%s","type":"user","message":{"role":"user","content":[{"type":"text","text":"hello"}]}}\n' "${user_iso}" > "${TUI_TRANSCRIPT}"
|
|
42
|
+
printf '{"timestamp":"%s","type":"assistant","message":{"role":"assistant","content":[{"type":"text","text":"done"}]}}\n' "${now_iso}" >> "${TUI_TRANSCRIPT}"
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
make_tui_sample_json() {
|
|
46
|
+
local resets_5h resets_7d
|
|
47
|
+
resets_5h=$(( $(date +%s) + 15480 ))
|
|
48
|
+
resets_7d=$(( $(date +%s) + 432000 ))
|
|
49
|
+
|
|
50
|
+
printf '{"model":{"id":"claude-sonnet-4-20250514","display_name":"Sonnet 4"},"cost":{"total_cost_usd":2.85,"message_cost_usd":0.12,"total_duration_ms":16200000,"total_api_duration_ms":480000,"total_lines_added":342,"total_lines_removed":87},"context_window":{"context_window_size":200000,"used_percentage":42,"total_input_tokens":72000,"total_output_tokens":12000,"current_usage":{"input_tokens":72000,"output_tokens":12000,"cache_creation_input_tokens":15000,"cache_read_input_tokens":8000}},"rate_limits":{"five_hour":{"used_percentage":35,"resets_at":%d},"seven_day":{"used_percentage":28,"resets_at":%d}},"cwd":"%s","workspace":{"current_dir":"%s","project_dir":"%s"},"session_id":"preview-123","version":"1.0.47"}' \
|
|
51
|
+
"${resets_5h}" "${resets_7d}" "${TUI_PREVIEW_CWD}" "${TUI_PREVIEW_CWD}" "${TUI_PREVIEW_CWD}"
|
|
52
|
+
}
|
|
10
53
|
|
|
11
54
|
readonly PREVIEW_CONFIG='{
|
|
12
55
|
"theme": "dark",
|
|
@@ -40,6 +83,7 @@ STYLE="minimal"
|
|
|
40
83
|
CHARSET="unicode"
|
|
41
84
|
COMPARE_STYLES=false
|
|
42
85
|
COMPARE_THEMES=false
|
|
86
|
+
COMPARE_TUI_LAYOUTS=false
|
|
43
87
|
BIN=""
|
|
44
88
|
TEMP_FILES=()
|
|
45
89
|
|
|
@@ -58,7 +102,8 @@ test_binary() {
|
|
|
58
102
|
|
|
59
103
|
find_binary() {
|
|
60
104
|
local npm_bin="${PLUGIN_ROOT}/../bin/claude-powerline"
|
|
61
|
-
|
|
105
|
+
local dist_file="${PLUGIN_ROOT}/../dist/index.mjs"
|
|
106
|
+
if [[ -f "${npm_bin}" ]] && [[ -f "${dist_file}" ]] && test_binary "${npm_bin}"; then
|
|
62
107
|
printf '%s' "${npm_bin}"
|
|
63
108
|
return 0
|
|
64
109
|
fi
|
|
@@ -98,14 +143,60 @@ run_preview() {
|
|
|
98
143
|
tmp_config="$(make_temp_config "${preview_theme}" "${preview_style}" "${preview_charset}")"
|
|
99
144
|
|
|
100
145
|
if [[ "${BIN}" == "npx" ]]; then
|
|
101
|
-
printf '%s' "${SAMPLE_JSON}" | npx -y @owloops/claude-powerline@latest \
|
|
146
|
+
printf '%s' "${SAMPLE_JSON}" | FORCE_COLOR=3 npx -y @owloops/claude-powerline@latest \
|
|
102
147
|
--config="${tmp_config}"
|
|
103
148
|
else
|
|
104
|
-
printf '%s' "${SAMPLE_JSON}" | "${BIN}" \
|
|
149
|
+
printf '%s' "${SAMPLE_JSON}" | FORCE_COLOR=3 "${BIN}" \
|
|
105
150
|
--config="${tmp_config}"
|
|
106
151
|
fi
|
|
107
152
|
}
|
|
108
153
|
|
|
154
|
+
run_preview_config() {
|
|
155
|
+
local config_file="$1"
|
|
156
|
+
local sample_data="$2"
|
|
157
|
+
|
|
158
|
+
if [[ "${BIN}" == "npx" ]]; then
|
|
159
|
+
printf '%s' "${sample_data}" | FORCE_COLOR=3 npx -y @owloops/claude-powerline@latest \
|
|
160
|
+
--config="${config_file}"
|
|
161
|
+
else
|
|
162
|
+
printf '%s' "${sample_data}" | FORCE_COLOR=3 "${BIN}" \
|
|
163
|
+
--config="${config_file}"
|
|
164
|
+
fi
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
run_compare_tui_layouts() {
|
|
168
|
+
local layouts=(compact standard full)
|
|
169
|
+
local label
|
|
170
|
+
local template_file tmp tui_json fake_repo
|
|
171
|
+
|
|
172
|
+
setup_tui_transcript
|
|
173
|
+
tui_json="$(make_tui_sample_json)"
|
|
174
|
+
fake_repo="${TUI_PREVIEW_CWD}"
|
|
175
|
+
|
|
176
|
+
for label in "${layouts[@]}"; do
|
|
177
|
+
template_file="${PLUGIN_ROOT}/templates/config-tui-${label}.json"
|
|
178
|
+
if [[ ! -f "${template_file}" ]]; then
|
|
179
|
+
printf '%s: template not found\n\n' "${label}"
|
|
180
|
+
continue
|
|
181
|
+
fi
|
|
182
|
+
|
|
183
|
+
tmp="$(mktemp)"
|
|
184
|
+
TEMP_FILES+=("${tmp}")
|
|
185
|
+
sed -e "s/replace:THEME/${THEME}/g" \
|
|
186
|
+
-e "s/replace:CHARSET/${CHARSET}/g" \
|
|
187
|
+
-e "s/\"replace:TODAY_BUDGET\"/50/g" \
|
|
188
|
+
"${template_file}" >"${tmp}"
|
|
189
|
+
|
|
190
|
+
printf '%s:\n' "${label}"
|
|
191
|
+
run_preview_config "${tmp}" "${tui_json}"
|
|
192
|
+
printf '\n\n'
|
|
193
|
+
done
|
|
194
|
+
|
|
195
|
+
# Clean up fake transcript and git repo
|
|
196
|
+
rm -f "${TUI_TRANSCRIPT}" 2>/dev/null
|
|
197
|
+
rm -rf "${fake_repo%/my-project}" 2>/dev/null
|
|
198
|
+
}
|
|
199
|
+
|
|
109
200
|
run_compare_styles() {
|
|
110
201
|
local styles=(minimal powerline capsule tui)
|
|
111
202
|
local s
|
|
@@ -175,6 +266,10 @@ parse_args() {
|
|
|
175
266
|
COMPARE_THEMES=true
|
|
176
267
|
shift
|
|
177
268
|
;;
|
|
269
|
+
--compare-tui-layouts)
|
|
270
|
+
COMPARE_TUI_LAYOUTS=true
|
|
271
|
+
shift
|
|
272
|
+
;;
|
|
178
273
|
*)
|
|
179
274
|
printf 'Unknown option: %s\n' "$1" >&2
|
|
180
275
|
exit 1
|
|
@@ -197,6 +292,11 @@ main() {
|
|
|
197
292
|
exit 0
|
|
198
293
|
fi
|
|
199
294
|
|
|
295
|
+
if [[ "${COMPARE_TUI_LAYOUTS}" == "true" ]]; then
|
|
296
|
+
run_compare_tui_layouts
|
|
297
|
+
exit 0
|
|
298
|
+
fi
|
|
299
|
+
|
|
200
300
|
run_preview "${THEME}" "${STYLE}" "${CHARSET}"
|
|
201
301
|
printf '\n'
|
|
202
302
|
exit 0
|
|
@@ -152,7 +152,57 @@ Then ask:
|
|
|
152
152
|
|
|
153
153
|
If the user chose `charset=text`, add a note that powerline and capsule use text fallback separators.
|
|
154
154
|
|
|
155
|
-
**If the user chose "tui":** skip Steps 5 and 6
|
|
155
|
+
**If the user chose "tui":** skip Steps 5 and 6 and continue to Step 4b for TUI layout selection.
|
|
156
|
+
|
|
157
|
+
## Step 4b: TUI Layout Selection
|
|
158
|
+
|
|
159
|
+
> [!NOTE]
|
|
160
|
+
> This step only applies if the user chose "tui" style in Step 4. Otherwise skip to Step 5.
|
|
161
|
+
|
|
162
|
+
Show a preview of all three TUI layouts using the bundled preview script.
|
|
163
|
+
|
|
164
|
+
> [!IMPORTANT]
|
|
165
|
+
> You MUST run the preview command below and let the terminal display the result.
|
|
166
|
+
> After running, tell the user to expand the bash output if they cannot see the previews.
|
|
167
|
+
|
|
168
|
+
```bash
|
|
169
|
+
${CLAUDE_PLUGIN_ROOT}/bin/preview.sh --compare-tui-layouts --theme=${chosen_theme} --charset=${charset}
|
|
170
|
+
```
|
|
171
|
+
|
|
172
|
+
After running the command, tell the user: "The three TUI layout previews are in the bash output above. Expand it if needed."
|
|
173
|
+
|
|
174
|
+
Display the three TUI layout presets:
|
|
175
|
+
|
|
176
|
+
````markdown
|
|
177
|
+
**Choose a TUI layout:**
|
|
178
|
+
|
|
179
|
+
1. **Compact** — Git + context window only
|
|
180
|
+
Minimal footprint. Model name in the title bar. Clean and focused.
|
|
181
|
+
|
|
182
|
+
2. **Standard** — Git + context + block usage with progress bars
|
|
183
|
+
Model and directory in the title bar. Good default for most users.
|
|
184
|
+
|
|
185
|
+
3. **Full** — Git, context, block, session, and daily cost
|
|
186
|
+
Title bar with model and directory. Footer with weekly usage and response time.
|
|
187
|
+
Maximum information density.
|
|
188
|
+
````
|
|
189
|
+
|
|
190
|
+
Then ask:
|
|
191
|
+
|
|
192
|
+
- **Question**: "Which TUI layout?"
|
|
193
|
+
- **Header**: "TUI Layout"
|
|
194
|
+
- **Options**:
|
|
195
|
+
- "Compact" -> Set `chosen_tui_layout=compact`
|
|
196
|
+
- "Standard" -> Set `chosen_tui_layout=standard`
|
|
197
|
+
- "Full" -> Set `chosen_tui_layout=full`
|
|
198
|
+
|
|
199
|
+
After selection, skip Steps 5 and 6 (always skipped for TUI). If "Compact" or "Standard", also skip Step 7 (no budget needed). If "Full", continue to Step 7.
|
|
200
|
+
|
|
201
|
+
### TUI preset to template mapping
|
|
202
|
+
|
|
203
|
+
- `compact` -> `config-tui-compact.json`
|
|
204
|
+
- `standard` -> `config-tui-standard.json`
|
|
205
|
+
- `full` -> `config-tui-full.json`
|
|
156
206
|
|
|
157
207
|
## Step 5: Segment Selection
|
|
158
208
|
|
|
@@ -190,7 +240,8 @@ Each preset has a corresponding template config file in `${CLAUDE_PLUGIN_ROOT}/t
|
|
|
190
240
|
- `essential` -> `config-essential.json`
|
|
191
241
|
- `standard` -> `config-standard.json`
|
|
192
242
|
- `full` -> `config-full.json`
|
|
193
|
-
|
|
243
|
+
|
|
244
|
+
For TUI templates, see Step 4b.
|
|
194
245
|
|
|
195
246
|
## Step 6: Bar Display Style
|
|
196
247
|
|
|
@@ -227,7 +278,7 @@ Apply `chosen_bar_style` to the `displayStyle` field of context, block, and week
|
|
|
227
278
|
## Step 7: Budget
|
|
228
279
|
|
|
229
280
|
> [!NOTE]
|
|
230
|
-
> Skip this step if the user chose "Essential" preset or "
|
|
281
|
+
> Skip this step if the user chose "Essential" preset, or TUI "Compact" or "Standard" layout. Only TUI "Full" layout uses a budget placeholder.
|
|
231
282
|
|
|
232
283
|
Ask the user about their daily budget for cost tracking:
|
|
233
284
|
|
|
@@ -258,7 +309,9 @@ If it exists, ask:
|
|
|
258
309
|
|
|
259
310
|
### Build and write the config
|
|
260
311
|
|
|
261
|
-
1. **Pick the template file.**
|
|
312
|
+
1. **Pick the template file.** Based on the user's choices:
|
|
313
|
+
- Non-TUI styles: `config-essential.json`, `config-standard.json`, or `config-full.json` (from Step 5)
|
|
314
|
+
- TUI style: `config-tui-compact.json`, `config-tui-standard.json`, or `config-tui-full.json` (from Step 4b)
|
|
262
315
|
|
|
263
316
|
2. **Read the template** using the Read tool:
|
|
264
317
|
|
|
@@ -271,12 +324,12 @@ ${CLAUDE_PLUGIN_ROOT}/templates/<template-file>
|
|
|
271
324
|
| Placeholder | Replace with |
|
|
272
325
|
|-------------|-------------|
|
|
273
326
|
| `replace:THEME` | The chosen theme (e.g., `tokyo-night`) |
|
|
274
|
-
| `replace:STYLE` | The chosen style (e.g., `capsule`). Not present in
|
|
327
|
+
| `replace:STYLE` | The chosen style (e.g., `capsule`). Not present in TUI templates. |
|
|
275
328
|
| `replace:CHARSET` | `unicode` or `text` |
|
|
276
|
-
| `replace:BAR_STYLE` | The chosen bar style (e.g., `blocks`). Default `text` if Step 6 was skipped. Not present in
|
|
277
|
-
| `replace:TODAY_BUDGET` | The budget number (e.g., `50`).
|
|
329
|
+
| `replace:BAR_STYLE` | The chosen bar style (e.g., `blocks`). Default `text` if Step 6 was skipped. Not present in TUI templates. |
|
|
330
|
+
| `replace:TODAY_BUDGET` | The budget number (e.g., `50`). Only present in non-TUI standard/full and TUI full templates. **Important:** replace `"replace:TODAY_BUDGET"` (including the surrounding quotes) with the bare number so the result is `"amount": 50` not `"amount": "50"`. |
|
|
278
331
|
|
|
279
|
-
1. **Handle "No budget"**: If the user chose "No budget" in Step 7, remove the entire `"amount": "replace:TODAY_BUDGET",` line (including the trailing comma) from the budget section. If Step 7 was skipped (essential preset), do not modify the budget section.
|
|
332
|
+
1. **Handle "No budget"**: If the user chose "No budget" in Step 7, remove the entire `"amount": "replace:TODAY_BUDGET",` line (including the trailing comma) from the budget section. If Step 7 was skipped (essential preset, or TUI compact/standard), do not modify the budget section.
|
|
280
333
|
|
|
281
334
|
1. **Write the result** to `~/.claude/claude-powerline.json` using the Write tool. Do NOT read or merge with any existing config.
|
|
282
335
|
|
|
@@ -331,3 +384,20 @@ Setup complete.
|
|
|
331
384
|
|
|
332
385
|
Documentation: https://github.com/Owloops/claude-powerline
|
|
333
386
|
````
|
|
387
|
+
|
|
388
|
+
**If the user chose TUI style**, also display:
|
|
389
|
+
|
|
390
|
+
````markdown
|
|
391
|
+
**Customizing your TUI grid layout:**
|
|
392
|
+
|
|
393
|
+
Edit `display.tui` in `~/.claude/claude-powerline.json` to fine-tune:
|
|
394
|
+
|
|
395
|
+
- **Box style** — Add `"box": "rounded"` to change borders. Presets: `rounded`, `square`, `heavy`, `double`, `dashed`, `heavy-dashed`, `mixed`, `ascii`, `invisible`
|
|
396
|
+
- **Title/footer** — Edit `title.left`, `title.right`, `footer.left`, `footer.right` using `{segment.part}` tokens (e.g. `{model.icon}`, `{dir}`, `{weekly.pct}`)
|
|
397
|
+
- **Grid areas** — Rearrange cells in `breakpoints[].areas`. Use `.` for empty cells, `---` for dividers. Repeat a name across adjacent cells to span columns
|
|
398
|
+
- **Custom colors** — Add `colors.custom` entries with dot-notation keys (e.g. `"context.bar": { "fg": "#4a9eff" }`)
|
|
399
|
+
- **Responsive breakpoints** — Add breakpoints for different terminal widths. The engine picks the largest `minWidth` that fits
|
|
400
|
+
- **Column sizing** — `"auto"` (fit content), `"1fr"` (fill remaining), or a fixed number like `"20"`
|
|
401
|
+
|
|
402
|
+
See the TUI Grid Layout section in the README for the full reference.
|
|
403
|
+
````
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
{
|
|
2
|
+
"theme": "replace:THEME",
|
|
3
|
+
"display": {
|
|
4
|
+
"style": "tui",
|
|
5
|
+
"charset": "replace:CHARSET",
|
|
6
|
+
"colorCompatibility": "auto",
|
|
7
|
+
"autoWrap": true,
|
|
8
|
+
"tui": {
|
|
9
|
+
"fitContent": true,
|
|
10
|
+
"minWidth": 50,
|
|
11
|
+
"padding": { "horizontal": 2 },
|
|
12
|
+
"separator": { "column": " " },
|
|
13
|
+
"title": {
|
|
14
|
+
"left": "{model}",
|
|
15
|
+
"right": "{dir}"
|
|
16
|
+
},
|
|
17
|
+
"breakpoints": [
|
|
18
|
+
{
|
|
19
|
+
"minWidth": 0,
|
|
20
|
+
"areas": [
|
|
21
|
+
"git.icon git.head . git.working",
|
|
22
|
+
"---",
|
|
23
|
+
"context.icon context.bar context.pct context.tokens"
|
|
24
|
+
],
|
|
25
|
+
"columns": ["auto", "1fr", "auto", "auto"],
|
|
26
|
+
"align": ["left", "left", "right", "right"]
|
|
27
|
+
}
|
|
28
|
+
]
|
|
29
|
+
},
|
|
30
|
+
"lines": [
|
|
31
|
+
{
|
|
32
|
+
"segments": {
|
|
33
|
+
"directory": { "enabled": true, "showBasename": true },
|
|
34
|
+
"git": { "enabled": true },
|
|
35
|
+
"model": { "enabled": true },
|
|
36
|
+
"context": { "enabled": true, "autocompactBuffer": 0 }
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
]
|
|
40
|
+
},
|
|
41
|
+
"colors": {
|
|
42
|
+
"custom": {
|
|
43
|
+
"model": { "fg": "#e0d68a" },
|
|
44
|
+
"dir": { "fg": "#d2e08a" },
|
|
45
|
+
"git": { "fg": "#c3e88d" },
|
|
46
|
+
"git.working": { "fg": "#90c499" },
|
|
47
|
+
"context": { "fg": "#7ecbc8" },
|
|
48
|
+
"context.pct": { "fg": "#71b7b4" },
|
|
49
|
+
"context.tokens": { "fg": "#71b7b4" }
|
|
50
|
+
}
|
|
51
|
+
},
|
|
52
|
+
"budget": {
|
|
53
|
+
"session": { "warningThreshold": 80 }
|
|
54
|
+
},
|
|
55
|
+
"modelContextLimits": {
|
|
56
|
+
"sonnet": 1000000,
|
|
57
|
+
"opus": 200000
|
|
58
|
+
}
|
|
59
|
+
}
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
{
|
|
2
|
+
"theme": "replace:THEME",
|
|
3
|
+
"display": {
|
|
4
|
+
"style": "tui",
|
|
5
|
+
"charset": "replace:CHARSET",
|
|
6
|
+
"colorCompatibility": "auto",
|
|
7
|
+
"autoWrap": true,
|
|
8
|
+
"tui": {
|
|
9
|
+
"fitContent": true,
|
|
10
|
+
"minWidth": 60,
|
|
11
|
+
"padding": { "horizontal": 2 },
|
|
12
|
+
"separator": { "column": " " },
|
|
13
|
+
"title": {
|
|
14
|
+
"left": "{model.icon} {model.value}",
|
|
15
|
+
"right": "{dir}"
|
|
16
|
+
},
|
|
17
|
+
"footer": {
|
|
18
|
+
"left": "{activity.durationIcon} {activity.durationVal} {activity.messagesIcon} {activity.messagesVal}",
|
|
19
|
+
"right": "{metrics.lastResponse}"
|
|
20
|
+
},
|
|
21
|
+
"segments": {
|
|
22
|
+
"git.info": {
|
|
23
|
+
"items": ["{branch}", "{status}", "{ahead}", "{behind}"],
|
|
24
|
+
"gap": 1
|
|
25
|
+
}
|
|
26
|
+
},
|
|
27
|
+
"breakpoints": [
|
|
28
|
+
{
|
|
29
|
+
"minWidth": 55,
|
|
30
|
+
"areas": [
|
|
31
|
+
"git.icon git.info git.info . git.working",
|
|
32
|
+
"---",
|
|
33
|
+
"context.icon context.bar context.bar context.pct context.tokens",
|
|
34
|
+
"block.icon block.bar block.bar block.value block.time",
|
|
35
|
+
"weekly.icon weekly.bar weekly.bar weekly.pct weekly.time",
|
|
36
|
+
"---",
|
|
37
|
+
"session session . today today"
|
|
38
|
+
],
|
|
39
|
+
"columns": ["auto", "1fr", "auto", "auto", "auto"],
|
|
40
|
+
"align": ["left", "left", "right", "right", "right"]
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
"minWidth": 0,
|
|
44
|
+
"areas": [
|
|
45
|
+
"git.head",
|
|
46
|
+
"git.working",
|
|
47
|
+
"---",
|
|
48
|
+
"context",
|
|
49
|
+
"block",
|
|
50
|
+
"---",
|
|
51
|
+
"session",
|
|
52
|
+
"today"
|
|
53
|
+
],
|
|
54
|
+
"columns": ["1fr"],
|
|
55
|
+
"align": ["left"]
|
|
56
|
+
}
|
|
57
|
+
]
|
|
58
|
+
},
|
|
59
|
+
"lines": [
|
|
60
|
+
{
|
|
61
|
+
"segments": {
|
|
62
|
+
"directory": { "enabled": true, "style": "fish" },
|
|
63
|
+
"git": { "enabled": true, "showAheadBehind": true },
|
|
64
|
+
"model": { "enabled": true },
|
|
65
|
+
"context": { "enabled": true, "autocompactBuffer": 0 },
|
|
66
|
+
"block": { "enabled": true, "type": "tokens" },
|
|
67
|
+
"session": { "enabled": true, "type": "tokens" },
|
|
68
|
+
"today": { "enabled": true, "type": "cost" },
|
|
69
|
+
"weekly": { "enabled": true },
|
|
70
|
+
"metrics": {
|
|
71
|
+
"enabled": true,
|
|
72
|
+
"showLastResponseTime": true,
|
|
73
|
+
"showResponseTime": false,
|
|
74
|
+
"showDuration": true,
|
|
75
|
+
"showMessageCount": true
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
]
|
|
80
|
+
},
|
|
81
|
+
"colors": {
|
|
82
|
+
"custom": {
|
|
83
|
+
"model": { "fg": "#e0d68a" },
|
|
84
|
+
"dir": { "fg": "#d2e08a" },
|
|
85
|
+
"git": { "fg": "#c3e88d" },
|
|
86
|
+
"git.working": { "fg": "#90c499" },
|
|
87
|
+
"context": { "fg": "#7ecbc8" },
|
|
88
|
+
"context.pct": { "fg": "#71b8cd" },
|
|
89
|
+
"context.tokens": { "fg": "#71b8cd" },
|
|
90
|
+
"block": { "fg": "#7dcfff" },
|
|
91
|
+
"block.value": { "fg": "#6fa6e2" },
|
|
92
|
+
"block.time": { "fg": "#6fa6e2" },
|
|
93
|
+
"weekly": { "fg": "#7aa2f7" },
|
|
94
|
+
"weekly.pct": { "fg": "#8b8ede" },
|
|
95
|
+
"weekly.time": { "fg": "#8b8ede" },
|
|
96
|
+
"session": { "fg": "#bb9af7" },
|
|
97
|
+
"today": { "fg": "#aaa0dd" },
|
|
98
|
+
"activity": { "fg": "#c0caf5" },
|
|
99
|
+
"metrics.lastResponse": { "fg": "#c0caf5" }
|
|
100
|
+
}
|
|
101
|
+
},
|
|
102
|
+
"budget": {
|
|
103
|
+
"session": { "warningThreshold": 80 },
|
|
104
|
+
"today": { "amount": "replace:TODAY_BUDGET", "warningThreshold": 80 }
|
|
105
|
+
},
|
|
106
|
+
"modelContextLimits": {
|
|
107
|
+
"sonnet": 1000000,
|
|
108
|
+
"opus": 200000
|
|
109
|
+
}
|
|
110
|
+
}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
{
|
|
2
|
+
"theme": "replace:THEME",
|
|
3
|
+
"display": {
|
|
4
|
+
"style": "tui",
|
|
5
|
+
"charset": "replace:CHARSET",
|
|
6
|
+
"colorCompatibility": "auto",
|
|
7
|
+
"autoWrap": true,
|
|
8
|
+
"tui": {
|
|
9
|
+
"fitContent": true,
|
|
10
|
+
"minWidth": 55,
|
|
11
|
+
"padding": { "horizontal": 2 },
|
|
12
|
+
"separator": { "column": " " },
|
|
13
|
+
"title": {
|
|
14
|
+
"left": "{model}",
|
|
15
|
+
"right": "{dir}"
|
|
16
|
+
},
|
|
17
|
+
"segments": {
|
|
18
|
+
"git.info": {
|
|
19
|
+
"items": ["{branch}", "{status}", "{ahead}", "{behind}"],
|
|
20
|
+
"gap": 1
|
|
21
|
+
}
|
|
22
|
+
},
|
|
23
|
+
"breakpoints": [
|
|
24
|
+
{
|
|
25
|
+
"minWidth": 0,
|
|
26
|
+
"areas": [
|
|
27
|
+
"git.icon git.info git.info . git.working",
|
|
28
|
+
"---",
|
|
29
|
+
"context.icon context.bar context.bar context.pct context.tokens",
|
|
30
|
+
"block.icon block.bar block.bar block.value block.time"
|
|
31
|
+
],
|
|
32
|
+
"columns": ["auto", "1fr", "auto", "auto", "auto"],
|
|
33
|
+
"align": ["left", "left", "right", "right", "right"]
|
|
34
|
+
}
|
|
35
|
+
]
|
|
36
|
+
},
|
|
37
|
+
"lines": [
|
|
38
|
+
{
|
|
39
|
+
"segments": {
|
|
40
|
+
"directory": { "enabled": true, "showBasename": true },
|
|
41
|
+
"git": { "enabled": true, "showAheadBehind": true },
|
|
42
|
+
"model": { "enabled": true },
|
|
43
|
+
"context": { "enabled": true, "autocompactBuffer": 0 },
|
|
44
|
+
"block": { "enabled": true, "type": "tokens" }
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
]
|
|
48
|
+
},
|
|
49
|
+
"colors": {
|
|
50
|
+
"custom": {
|
|
51
|
+
"model": { "fg": "#e0d68a" },
|
|
52
|
+
"dir": { "fg": "#d2e08a" },
|
|
53
|
+
"git": { "fg": "#c3e88d" },
|
|
54
|
+
"git.working": { "fg": "#90c499" },
|
|
55
|
+
"context": { "fg": "#7ecbc8" },
|
|
56
|
+
"context.pct": { "fg": "#70a4c9" },
|
|
57
|
+
"context.tokens": { "fg": "#70a4c9" },
|
|
58
|
+
"block": { "fg": "#7aa2f7" },
|
|
59
|
+
"block.value": { "fg": "#6e92de" },
|
|
60
|
+
"block.time": { "fg": "#6e92de" }
|
|
61
|
+
}
|
|
62
|
+
},
|
|
63
|
+
"budget": {
|
|
64
|
+
"session": { "warningThreshold": 80 }
|
|
65
|
+
},
|
|
66
|
+
"modelContextLimits": {
|
|
67
|
+
"sonnet": 1000000,
|
|
68
|
+
"opus": 200000
|
|
69
|
+
}
|
|
70
|
+
}
|