codicent-cli 0.8.4__tar.gz → 0.8.5__tar.gz

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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: codicent-cli
3
- Version: 0.8.4
3
+ Version: 0.8.5
4
4
  Summary: Command-line interface for the Codicent API
5
5
  Home-page: https://github.com/izaxon/codicent-cli
6
6
  Author: Johan Isaksson
@@ -123,6 +123,23 @@ TERMINAL (Web Terminal Host):
123
123
  codicent terminal bash
124
124
  codicent terminal zsh
125
125
 
126
+ TUI (Text User Interface):
127
+ tui Open a split-screen terminal UI with a logbook home panel on
128
+ the left (recent messages + compose) and an AI chat panel on
129
+ the right. Uses the same authentication as other commands.
130
+
131
+ Key bindings:
132
+ Tab / Shift+Tab Switch focus between compose and chat inputs
133
+ Enter Send the current input
134
+ Escape + Enter Insert a newline in the active input
135
+ Ctrl+R Refresh message list
136
+ F1 or Alt+1 Focus compose input
137
+ F2 or Alt+2 Focus chat input
138
+ Ctrl+C Quit
139
+
140
+ Example:
141
+ codicent tui
142
+
126
143
  EXAMPLES:
127
144
  codicent auth
128
145
  codicent "What is Python?"
@@ -133,6 +150,7 @@ EXAMPLES:
133
150
  codicent wrap claude
134
151
  codicent terminal
135
152
  codicent daemon
153
+ codicent tui
136
154
  codicent update
137
155
  codicent update --install
138
156
  echo "Help me debug this" | codicent
@@ -1015,6 +1033,31 @@ def main():
1015
1033
  project=wrap_project,
1016
1034
  )
1017
1035
 
1036
+ # Handle tui command
1037
+ if len(sys.argv) > 1 and sys.argv[1] == "tui":
1038
+ from tui import run_tui
1039
+
1040
+ tui_token = auth.get_cached_token()
1041
+ if not tui_token:
1042
+ tui_token = os.getenv("CODICENT_TOKEN")
1043
+ if not tui_token:
1044
+ console.print("[red]❌ No authentication found.[/red]")
1045
+ console.print("[dim]Run 'codicent auth' to authenticate, or set CODICENT_TOKEN[/dim]")
1046
+ return 1
1047
+
1048
+ try:
1049
+ tui_payload = tui_token.split(".")[1]
1050
+ tui_payload += '=' * (-len(tui_payload) % 4)
1051
+ tui_jwt = json.loads(base64.urlsafe_b64decode(tui_payload).decode('utf-8'))
1052
+ tui_project = tui_jwt["project"]
1053
+ except Exception as e:
1054
+ console.print(f"[red]❌ Failed to extract project from token: {e}[/red]")
1055
+ return 1
1056
+
1057
+ tui_codicent = Codicent(tui_token)
1058
+ run_tui(tui_codicent, tui_project)
1059
+ return 0
1060
+
1018
1061
  # Handle terminal command
1019
1062
  if len(sys.argv) > 1 and sys.argv[1] == "terminal":
1020
1063
  from terminal import run_terminal_host
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: codicent-cli
3
- Version: 0.8.4
3
+ Version: 0.8.5
4
4
  Summary: Command-line interface for the Codicent API
5
5
  Home-page: https://github.com/izaxon/codicent-cli
6
6
  Author: Johan Isaksson
@@ -9,7 +9,7 @@ except FileNotFoundError:
9
9
 
10
10
  setup(
11
11
  name='codicent-cli',
12
- version='0.8.4',
12
+ version='0.8.5',
13
13
  author='Johan Isaksson',
14
14
  author_email='johan@izaxon.com',
15
15
  description='Command-line interface for the Codicent API',
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes