gemcode 0.3.52__py3-none-any.whl → 0.3.53__py3-none-any.whl
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.
- gemcode/tui/welcome_banner.py +59 -49
- {gemcode-0.3.52.dist-info → gemcode-0.3.53.dist-info}/METADATA +1 -1
- {gemcode-0.3.52.dist-info → gemcode-0.3.53.dist-info}/RECORD +7 -7
- {gemcode-0.3.52.dist-info → gemcode-0.3.53.dist-info}/WHEEL +0 -0
- {gemcode-0.3.52.dist-info → gemcode-0.3.53.dist-info}/entry_points.txt +0 -0
- {gemcode-0.3.52.dist-info → gemcode-0.3.53.dist-info}/licenses/LICENSE +0 -0
- {gemcode-0.3.52.dist-info → gemcode-0.3.53.dist-info}/top_level.txt +0 -0
gemcode/tui/welcome_banner.py
CHANGED
|
@@ -10,21 +10,21 @@ from gemcode.vertex import vertex_env_active
|
|
|
10
10
|
from gemcode.workspace_hints import narrow_workspace_tip
|
|
11
11
|
|
|
12
12
|
_GEM_LINES = (
|
|
13
|
-
r"
|
|
14
|
-
r"
|
|
15
|
-
r"
|
|
16
|
-
r"
|
|
17
|
-
r"
|
|
18
|
-
r"
|
|
13
|
+
r"██████╗ ███████╗███╗ ███╗",
|
|
14
|
+
r"██╔════╝ ██╔════╝████╗ ████║",
|
|
15
|
+
r"██║ ███╗█████╗ ██╔████╔██║",
|
|
16
|
+
r"██║ ██║██╔══╝ ██║╚██╔╝██║",
|
|
17
|
+
r"╚██████╔╝███████╗██║ ╚═╝ ██║",
|
|
18
|
+
r" ╚═════╝ ╚══════╝╚═╝ ╚═╝",
|
|
19
19
|
)
|
|
20
20
|
|
|
21
21
|
_CODE_LINES = (
|
|
22
|
-
r"
|
|
23
|
-
r"
|
|
24
|
-
r"
|
|
25
|
-
r"
|
|
26
|
-
r"
|
|
27
|
-
r"
|
|
22
|
+
r"██████╗ ██████╗ ██████╗ ███████╗",
|
|
23
|
+
r"██╔════╝██╔═══██╗██╔══██╗██╔════╝",
|
|
24
|
+
r"██║ ██║ ██║██║ ██║█████╗ ",
|
|
25
|
+
r"██║ ██║ ██║██║ ██║██╔══╝ ",
|
|
26
|
+
r"╚██████╗╚██████╔╝██████╔╝███████╗",
|
|
27
|
+
r" ╚═════╝ ╚═════╝ ╚═════╝ ╚══════╝",
|
|
28
28
|
)
|
|
29
29
|
|
|
30
30
|
_TAGLINE = "✦ Gemini-powered coding agent. Fast. Capable. Local. ✦"
|
|
@@ -72,56 +72,66 @@ def _kv_line(inner: int, label: str, value: str) -> str:
|
|
|
72
72
|
|
|
73
73
|
|
|
74
74
|
def format_welcome_banner(cfg, *, term_width: int = 100) -> str:
|
|
75
|
-
inner = min(60, max(48, term_width - 4))
|
|
76
|
-
top = "╔" + ("═" * inner) + "╗"
|
|
77
|
-
mid = "╠" + ("═" * inner) + "╣"
|
|
78
|
-
bot = "╚" + ("═" * inner) + "╝"
|
|
79
|
-
|
|
80
75
|
provider, model, endpoint = _provider_model_endpoint(cfg)
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
mode = "vertex" if vertex_env_active() else "cloud"
|
|
86
|
-
status_raw = f" ● {mode} Ready — type /help to begin"
|
|
87
|
-
if len(status_raw) > inner:
|
|
88
|
-
status_raw = status_raw[: max(0, inner - 3)] + "..."
|
|
89
|
-
row_s = status_raw.ljust(inner)[:inner]
|
|
76
|
+
# Banner style: "solid" removes the boxed provider block and blank spacer
|
|
77
|
+
# lines for a single rigid header (OpenClaude-like).
|
|
78
|
+
style = (os.environ.get("GEMCODE_TUI_BANNER_STYLE", "solid") or "solid").strip().lower()
|
|
90
79
|
|
|
91
|
-
bw = max(_banner_width(),
|
|
80
|
+
bw = max(_banner_width(), min(80, max(48, term_width)))
|
|
92
81
|
lines: list[str] = []
|
|
93
82
|
for row in _GEM_LINES:
|
|
94
83
|
lines.append(_center(row, bw))
|
|
95
|
-
lines.append("")
|
|
96
84
|
for row in _CODE_LINES:
|
|
97
85
|
lines.append(_center(row, bw))
|
|
98
|
-
lines.append(
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
86
|
+
lines.append(_center(_TAGLINE, bw))
|
|
87
|
+
|
|
88
|
+
if style not in ("solid", "rigid", "compact"):
|
|
89
|
+
# Backward-compat: unknown values fall back to the old boxed layout.
|
|
90
|
+
style = "boxed"
|
|
91
|
+
|
|
92
|
+
if style == "boxed":
|
|
93
|
+
inner = min(60, max(48, term_width - 4))
|
|
94
|
+
top = "╔" + ("═" * inner) + "╗"
|
|
95
|
+
mid = "╠" + ("═" * inner) + "╣"
|
|
96
|
+
bot = "╚" + ("═" * inner) + "╝"
|
|
97
|
+
|
|
98
|
+
row_p = _kv_line(inner, "Provider", provider)
|
|
99
|
+
row_m = _kv_line(inner, "Model", model)
|
|
100
|
+
row_e = _kv_line(inner, "Endpoint", endpoint)
|
|
101
|
+
|
|
102
|
+
mode = "vertex" if vertex_env_active() else "cloud"
|
|
103
|
+
status_raw = f" ● {mode} Ready — type /help to begin"
|
|
104
|
+
if len(status_raw) > inner:
|
|
105
|
+
status_raw = status_raw[: max(0, inner - 3)] + "..."
|
|
106
|
+
row_s = status_raw.ljust(inner)[:inner]
|
|
107
|
+
|
|
108
|
+
box_w = inner + 2
|
|
109
|
+
pad_b = max(0, (bw - box_w) // 2)
|
|
110
|
+
bp = " " * pad_b
|
|
111
|
+
|
|
112
|
+
def box_row(body: str) -> str:
|
|
113
|
+
b = body[:inner].ljust(inner)
|
|
114
|
+
return bp + "│" + b + "│"
|
|
115
|
+
|
|
116
|
+
lines.append(bp + top)
|
|
117
|
+
lines.append(box_row(row_p))
|
|
118
|
+
lines.append(box_row(row_m))
|
|
119
|
+
lines.append(box_row(row_e))
|
|
120
|
+
lines.append(bp + mid)
|
|
121
|
+
lines.append(box_row(row_s))
|
|
122
|
+
lines.append(bp + bot)
|
|
123
|
+
else:
|
|
124
|
+
# Solid header: one rigid info line, no extra blocks.
|
|
125
|
+
mode = "vertex" if vertex_env_active() else "cloud"
|
|
126
|
+
info = f"{provider} · {model} · {endpoint} · {mode} ready — type /help"
|
|
127
|
+
lines.append(_center(info, bw))
|
|
117
128
|
|
|
118
129
|
ver = os.environ.get("GEMCODE_VERSION", get_version())
|
|
119
|
-
lines.append(_center(f"
|
|
130
|
+
lines.append(_center(f"gemcode v{ver}", bw))
|
|
120
131
|
|
|
121
132
|
root = getattr(cfg, "project_root", None)
|
|
122
133
|
if isinstance(root, Path):
|
|
123
134
|
nt = narrow_workspace_tip(root)
|
|
124
135
|
if nt:
|
|
125
136
|
lines.append(_center(nt, bw))
|
|
126
|
-
lines.append("")
|
|
127
137
|
return "\n".join(lines)
|
|
@@ -75,14 +75,14 @@ gemcode/tools/web.py,sha256=ULg1e3inG4FjPSUCYI8dVBzTrcCHINNRo76SIU9qw-A,4489
|
|
|
75
75
|
gemcode/tui/input_handler.py,sha256=Off7hBXXqw7JxkKzlmtMHtg25Y9dkO275dC35brK-TE,10676
|
|
76
76
|
gemcode/tui/scrollback.py,sha256=RxwS0DsjkkX_jHvnlF2XMi9z69yGfCiwPuFIHCnb8VU,32535
|
|
77
77
|
gemcode/tui/spinner.py,sha256=AJrApG5od-Sh40-5uWcNM9RHb5ax7gr-NbgAZmTbIYY,4848
|
|
78
|
-
gemcode/tui/welcome_banner.py,sha256=
|
|
78
|
+
gemcode/tui/welcome_banner.py,sha256=DLm-Zhi194zYFNCJ5qQdikPTIvaD3rf9EXJjuW1_0x0,4981
|
|
79
79
|
gemcode/tui/welcome_rich.py,sha256=8FEZzLXrzqly5JWiDgV9ooRV1LNXDk-CXV1a7K6ua-U,4048
|
|
80
80
|
gemcode/web/__init__.py,sha256=EysmUAWs6g-lmMk4VFljKfaHVrEgb_FiIzwQmBdORJc,40
|
|
81
81
|
gemcode/web/claude_sse_adapter.py,sha256=HcNp0Lh4DdBZBLOpstsqa-VzfqAUrRngZ6FSuJ-mIMg,8609
|
|
82
82
|
gemcode/web/terminal_repl.py,sha256=k2irvFGbCY8gDm_pbirR7b_cakaeafcctoTIvnJkVXk,3902
|
|
83
|
-
gemcode-0.3.
|
|
84
|
-
gemcode-0.3.
|
|
85
|
-
gemcode-0.3.
|
|
86
|
-
gemcode-0.3.
|
|
87
|
-
gemcode-0.3.
|
|
88
|
-
gemcode-0.3.
|
|
83
|
+
gemcode-0.3.53.dist-info/licenses/LICENSE,sha256=TD4524qn-W8Z07GTDnag-9jJPFutFZNB0a1WbMHPC54,8388
|
|
84
|
+
gemcode-0.3.53.dist-info/METADATA,sha256=b1pSz3zOjci_o1s66dLdgMXQM9UlM1QxJlzdbY3oVn8,23695
|
|
85
|
+
gemcode-0.3.53.dist-info/WHEEL,sha256=aeYiig01lYGDzBgS8HxWXOg3uV61G9ijOsup-k9o1sk,91
|
|
86
|
+
gemcode-0.3.53.dist-info/entry_points.txt,sha256=cZdLTLDiHbks7OSUCuxCh66dCWeQdpLR8BozoqfEjV4,45
|
|
87
|
+
gemcode-0.3.53.dist-info/top_level.txt,sha256=UYrjULLBY2bcgK6KI6flomJWmsbDXu7n0rvW2SWFrbo,8
|
|
88
|
+
gemcode-0.3.53.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|